@crewx/cli 0.8.3-rc.8 → 0.8.3
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.
|
@@ -18,10 +18,10 @@ export declare function readStdin(): Promise<string>;
|
|
|
18
18
|
* Resolve the final prompt from argv, stdin pipe, or --prompt-file.
|
|
19
19
|
*
|
|
20
20
|
* Priority:
|
|
21
|
-
* 1. promptFile is specified → read file content
|
|
22
|
-
* 2.
|
|
23
|
-
* 3. argv
|
|
24
|
-
* 4.
|
|
21
|
+
* 1. promptFile is specified → read file content
|
|
22
|
+
* 2. argv is present → use argv (stdin is NOT read — prevents hang in child processes)
|
|
23
|
+
* 3. argv is empty, no promptFile → read stdin pipe/redirect
|
|
24
|
+
* 4. argv + promptFile both present → `${argv}\n\n${fileContent}`
|
|
25
25
|
* 5. Neither present → return '' (caller decides error handling)
|
|
26
26
|
*
|
|
27
27
|
* @param _readStdin - injectable stdin reader, defaults to the module-level
|
|
@@ -30,10 +30,10 @@ async function readStdin() {
|
|
|
30
30
|
* Resolve the final prompt from argv, stdin pipe, or --prompt-file.
|
|
31
31
|
*
|
|
32
32
|
* Priority:
|
|
33
|
-
* 1. promptFile is specified → read file content
|
|
34
|
-
* 2.
|
|
35
|
-
* 3. argv
|
|
36
|
-
* 4.
|
|
33
|
+
* 1. promptFile is specified → read file content
|
|
34
|
+
* 2. argv is present → use argv (stdin is NOT read — prevents hang in child processes)
|
|
35
|
+
* 3. argv is empty, no promptFile → read stdin pipe/redirect
|
|
36
|
+
* 4. argv + promptFile both present → `${argv}\n\n${fileContent}`
|
|
37
37
|
* 5. Neither present → return '' (caller decides error handling)
|
|
38
38
|
*
|
|
39
39
|
* @param _readStdin - injectable stdin reader, defaults to the module-level
|
|
@@ -45,7 +45,7 @@ async function resolvePrompt(argvPrompt, promptFile, _readStdin = readStdin) {
|
|
|
45
45
|
if (promptFile) {
|
|
46
46
|
external = (0, fs_1.readFileSync)(promptFile, 'utf8').trimEnd();
|
|
47
47
|
}
|
|
48
|
-
else {
|
|
48
|
+
else if (!argvPrompt) {
|
|
49
49
|
external = (await _readStdin()).trimEnd();
|
|
50
50
|
}
|
|
51
51
|
if (argvPrompt && external)
|
package/dist/main.js
CHANGED
|
@@ -250,6 +250,7 @@ Query / Execute:
|
|
|
250
250
|
--config/-c <path> Config file path (default: CREWX_CONFIG or crewx.yaml)
|
|
251
251
|
--output-format <fmt> Output format (json|text|stream-json)
|
|
252
252
|
--effort <level> Model effort (high|medium|low)
|
|
253
|
+
-f/--prompt-file <path> Read task body from file (bypasses argv length limits)
|
|
253
254
|
-- End of flags; remaining tokens treated as message text
|
|
254
255
|
e.g. crewx q "@agent label" -- --flag-in-message
|
|
255
256
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@crewx/cli",
|
|
3
|
-
"version": "0.8.3
|
|
3
|
+
"version": "0.8.3",
|
|
4
4
|
"license": "UNLICENSED",
|
|
5
5
|
"engines": {
|
|
6
6
|
"node": ">=20.19.0"
|
|
@@ -27,15 +27,15 @@
|
|
|
27
27
|
"dependencies": {
|
|
28
28
|
"@crewx/adapter-slack": "^0.1.4",
|
|
29
29
|
"better-sqlite3": "*",
|
|
30
|
-
"@crewx/sdk": "0.8.3
|
|
31
|
-
"@crewx/
|
|
32
|
-
"@crewx/
|
|
33
|
-
"@crewx/
|
|
34
|
-
"@crewx/
|
|
35
|
-
"@crewx/cron": "0.1.
|
|
36
|
-
"@crewx/
|
|
37
|
-
"@crewx/
|
|
38
|
-
"@crewx/shared": "0.0.
|
|
30
|
+
"@crewx/sdk": "0.8.3",
|
|
31
|
+
"@crewx/memory": "0.1.10",
|
|
32
|
+
"@crewx/search": "0.1.9",
|
|
33
|
+
"@crewx/wbs": "0.1.9",
|
|
34
|
+
"@crewx/doc": "0.1.8",
|
|
35
|
+
"@crewx/cron": "0.1.8",
|
|
36
|
+
"@crewx/skill": "0.1.8",
|
|
37
|
+
"@crewx/workflow": "0.3.17",
|
|
38
|
+
"@crewx/shared": "0.0.5"
|
|
39
39
|
},
|
|
40
40
|
"devDependencies": {
|
|
41
41
|
"@types/better-sqlite3": "*",
|