@anthropic-ai/claude-code 2.1.2 → 2.1.4
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/cli.js +2188 -2207
- package/package.json +1 -1
- package/sdk-tools.d.ts +25 -10
package/package.json
CHANGED
package/sdk-tools.d.ts
CHANGED
|
@@ -69,18 +69,17 @@ export interface BashInput {
|
|
|
69
69
|
*/
|
|
70
70
|
timeout?: number;
|
|
71
71
|
/**
|
|
72
|
-
* Clear, concise description of what this command does in
|
|
73
|
-
* Input: ls
|
|
74
|
-
* Output: List files in current directory
|
|
72
|
+
* Clear, concise description of what this command does in active voice. Never use words like "complex" or "risk" in the description - just describe what it does.
|
|
75
73
|
*
|
|
76
|
-
*
|
|
77
|
-
*
|
|
74
|
+
* For simple commands (git, npm, standard CLI tools), keep it brief (5-10 words):
|
|
75
|
+
* - ls → "List files in current directory"
|
|
76
|
+
* - git status → "Show working tree status"
|
|
77
|
+
* - npm install → "Install package dependencies"
|
|
78
78
|
*
|
|
79
|
-
*
|
|
80
|
-
*
|
|
81
|
-
*
|
|
82
|
-
*
|
|
83
|
-
* Output: Create directory 'foo'
|
|
79
|
+
* For commands that are harder to parse at a glance (piped commands, obscure flags, etc.), add enough context to clarify what it does:
|
|
80
|
+
* - find . -name "*.tmp" -exec rm {} \; → "Find and delete all .tmp files recursively"
|
|
81
|
+
* - git reset --hard origin/main → "Discard all local changes and match remote main"
|
|
82
|
+
* - curl -s url | jq '.data[]' → "Fetch JSON from URL and extract data array elements"
|
|
84
83
|
*/
|
|
85
84
|
description?: string;
|
|
86
85
|
/**
|
|
@@ -91,6 +90,13 @@ export interface BashInput {
|
|
|
91
90
|
* Set this to true to dangerously override sandbox mode and run commands without sandboxing.
|
|
92
91
|
*/
|
|
93
92
|
dangerouslyDisableSandbox?: boolean;
|
|
93
|
+
/**
|
|
94
|
+
* Internal: pre-computed sed edit result from preview
|
|
95
|
+
*/
|
|
96
|
+
_simulatedSedEdit?: {
|
|
97
|
+
filePath: string;
|
|
98
|
+
newContent: string;
|
|
99
|
+
};
|
|
94
100
|
}
|
|
95
101
|
export interface TaskOutputInput {
|
|
96
102
|
/**
|
|
@@ -1488,6 +1494,15 @@ export interface AskUserQuestionInput {
|
|
|
1488
1494
|
answers?: {
|
|
1489
1495
|
[k: string]: string;
|
|
1490
1496
|
};
|
|
1497
|
+
/**
|
|
1498
|
+
* Optional metadata for tracking and analytics purposes. Not displayed to user.
|
|
1499
|
+
*/
|
|
1500
|
+
metadata?: {
|
|
1501
|
+
/**
|
|
1502
|
+
* Optional identifier for the source of this question (e.g., "remember" for /remember command). Used for analytics tracking.
|
|
1503
|
+
*/
|
|
1504
|
+
source?: string;
|
|
1505
|
+
};
|
|
1491
1506
|
}
|
|
1492
1507
|
export interface ConfigInput {
|
|
1493
1508
|
/**
|