@lazehq/cli 0.1.129 → 0.1.130
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/laze.mjs +8 -12
- package/package.json +1 -1
package/dist/laze.mjs
CHANGED
|
@@ -36960,7 +36960,7 @@ function shadowedLinkLineOf({ shadow }) {
|
|
|
36960
36960
|
}
|
|
36961
36961
|
|
|
36962
36962
|
// src/rules/cli-version.rules.ts
|
|
36963
|
-
var STAMPED = "0.1.
|
|
36963
|
+
var STAMPED = "0.1.130";
|
|
36964
36964
|
function cliVersionOf({ stamped = STAMPED } = {}) {
|
|
36965
36965
|
return stamped.startsWith("__") ? "dev" : stamped;
|
|
36966
36966
|
}
|
|
@@ -89656,7 +89656,7 @@ async function channelSettings({ context, args }) {
|
|
|
89656
89656
|
|
|
89657
89657
|
// src/services/chat-actions-commands.service.ts
|
|
89658
89658
|
import { readFile as readFile19 } from "node:fs/promises";
|
|
89659
|
-
import { basename as basename9,
|
|
89659
|
+
import { basename as basename9, resolve as resolve11 } from "node:path";
|
|
89660
89660
|
|
|
89661
89661
|
// src/rules/app-link.rules.ts
|
|
89662
89662
|
var MARKDOWN_LINK = /^\[[^\]]*\]\((\S+)\)$/;
|
|
@@ -89876,7 +89876,7 @@ var CHAT_ACTIONS_USAGE = `Usage:
|
|
|
89876
89876
|
laze file link <fileId> [--variant original|thumbnail|poster|preview] [--download]
|
|
89877
89877
|
laze file download <fileId> [--out <path>] save a file to disk, up to 1 GB
|
|
89878
89878
|
laze file rename <fileId> <name> rename a file you posted
|
|
89879
|
-
laze file upload <channel> <path> [--name <name>] [--type <content-type>] upload a file; post it with its id
|
|
89879
|
+
laze file upload <channel> <path> [--name <name>] [--type <content-type>] upload a file under its own name (or --name); post it with its id
|
|
89880
89880
|
laze saved [--done] [--limit <n>] | laze saved marks your saved messages (people)
|
|
89881
89881
|
laze save <messageId> [--off] save a message for later, or take it out
|
|
89882
89882
|
laze saved done <messageId> [--undo] mark a saved message done, or open again
|
|
@@ -90100,10 +90100,6 @@ var files = async ({ context, args, client }) => {
|
|
|
90100
90100
|
}).join("") || "No files.\n"
|
|
90101
90101
|
});
|
|
90102
90102
|
};
|
|
90103
|
-
function uploadNameOf({ cwd, path }) {
|
|
90104
|
-
const inside = relative4(cwd, path);
|
|
90105
|
-
return inside && !inside.startsWith("..") && !isAbsolute2(inside) ? inside : basename9(path);
|
|
90106
|
-
}
|
|
90107
90103
|
var fileUpload = async ({ context, args, client }) => {
|
|
90108
90104
|
const path = resolve11(context.cwd, wordAt(args, 3));
|
|
90109
90105
|
const bytes = new Uint8Array(await readFile19(path));
|
|
@@ -90113,7 +90109,7 @@ var fileUpload = async ({ context, args, client }) => {
|
|
|
90113
90109
|
file: {
|
|
90114
90110
|
channel: wordAt(args, 2),
|
|
90115
90111
|
fileName: readableUploadName({
|
|
90116
|
-
name:
|
|
90112
|
+
name: basename9(path),
|
|
90117
90113
|
...flagText({ args, name: "name" }) && { asked: flagText({ args, name: "name" }) }
|
|
90118
90114
|
}),
|
|
90119
90115
|
contentType: flagText({ args, name: "type", fallback: contentTypeOf(path) }),
|
|
@@ -101072,7 +101068,7 @@ import { join as join32, resolve as resolve20 } from "node:path";
|
|
|
101072
101068
|
|
|
101073
101069
|
// src/services/mount-files.service.ts
|
|
101074
101070
|
import { mkdir as mkdir11, readFile as readFile30, rm as rm18, writeFile as writeFile8 } from "node:fs/promises";
|
|
101075
|
-
import { dirname as dirname23, relative as
|
|
101071
|
+
import { dirname as dirname23, relative as relative4, resolve as resolve19 } from "node:path";
|
|
101076
101072
|
async function textArgument({
|
|
101077
101073
|
context,
|
|
101078
101074
|
value
|
|
@@ -101095,7 +101091,7 @@ async function writeMount({
|
|
|
101095
101091
|
await mkdir11(root, { recursive: true });
|
|
101096
101092
|
for (const file4 of files2) {
|
|
101097
101093
|
const target = resolve19(root, file4.path);
|
|
101098
|
-
const inside =
|
|
101094
|
+
const inside = relative4(root, target);
|
|
101099
101095
|
if (!inside || inside.startsWith(".."))
|
|
101100
101096
|
throw new Error(`Refusing to write outside ${root}: ${file4.path}`);
|
|
101101
101097
|
await mkdir11(dirname23(target), { recursive: true });
|
|
@@ -104399,7 +104395,7 @@ async function schedule({ context, args }) {
|
|
|
104399
104395
|
|
|
104400
104396
|
// src/services/skill-commands.service.ts
|
|
104401
104397
|
import { readdir as readdir8, readFile as readFile33 } from "node:fs/promises";
|
|
104402
|
-
import { join as join35, relative as
|
|
104398
|
+
import { join as join35, relative as relative5, resolve as resolve22 } from "node:path";
|
|
104403
104399
|
var USAGE18 = `Usage:
|
|
104404
104400
|
laze skill list [--agent <agentId>]
|
|
104405
104401
|
laze skill install <catalogue-id> [--as <name>] [--agent <agentId>]
|
|
@@ -104421,7 +104417,7 @@ async function folderFiles({ root }) {
|
|
|
104421
104417
|
for (const entry2 of entries) {
|
|
104422
104418
|
if (!entry2.isFile()) continue;
|
|
104423
104419
|
const full = join35(entry2.parentPath, entry2.name);
|
|
104424
|
-
files2.push({ path:
|
|
104420
|
+
files2.push({ path: relative5(root, full), content: await readFile33(full, "utf8") });
|
|
104425
104421
|
}
|
|
104426
104422
|
return files2.toSorted((a, b) => a.path.localeCompare(b.path));
|
|
104427
104423
|
}
|
package/package.json
CHANGED