@damper/cli 0.2.3 → 0.3.0
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/commands/start.d.ts +1 -0
- package/dist/commands/start.js +1 -0
- package/dist/index.js +5 -1
- package/dist/services/claude.d.ts +1 -0
- package/dist/services/claude.js +13 -3
- package/package.json +1 -1
package/dist/commands/start.d.ts
CHANGED
package/dist/commands/start.js
CHANGED
package/dist/index.js
CHANGED
|
@@ -4,7 +4,7 @@ import { startCommand } from './commands/start.js';
|
|
|
4
4
|
import { statusCommand } from './commands/status.js';
|
|
5
5
|
import { cleanupCommand } from './commands/cleanup.js';
|
|
6
6
|
import { setupCommand } from './commands/setup.js';
|
|
7
|
-
const VERSION = '0.
|
|
7
|
+
const VERSION = '0.3.0';
|
|
8
8
|
function showHelp() {
|
|
9
9
|
console.log(`
|
|
10
10
|
${pc.bold('@damper/cli')} - Agent orchestration for Damper tasks
|
|
@@ -19,6 +19,7 @@ ${pc.bold('Options:')}
|
|
|
19
19
|
--task <id> Work on a specific task
|
|
20
20
|
--type <type> Filter by type: bug, feature, improvement, task
|
|
21
21
|
--status <status> Filter by status: planned, in_progress, done, all
|
|
22
|
+
--yolo Skip plan mode, auto-accept edits
|
|
22
23
|
--reconfigure Change API key (use with setup command)
|
|
23
24
|
-h, --help Show this help message
|
|
24
25
|
-v, --version Show version
|
|
@@ -80,6 +81,9 @@ function parseArgs(args) {
|
|
|
80
81
|
else if (arg === '--reconfigure') {
|
|
81
82
|
result.setupOptions.reconfigure = true;
|
|
82
83
|
}
|
|
84
|
+
else if (arg === '--yolo') {
|
|
85
|
+
result.options.yolo = true;
|
|
86
|
+
}
|
|
83
87
|
else if (!arg.startsWith('-') && !result.command) {
|
|
84
88
|
result.command = arg;
|
|
85
89
|
}
|
package/dist/services/claude.js
CHANGED
|
@@ -83,8 +83,14 @@ export function configureDamperMcp() {
|
|
|
83
83
|
* Launch Claude Code in a directory
|
|
84
84
|
*/
|
|
85
85
|
export async function launchClaude(options) {
|
|
86
|
-
const { cwd, taskId, taskTitle, apiKey } = options;
|
|
86
|
+
const { cwd, taskId, taskTitle, apiKey, yolo } = options;
|
|
87
87
|
console.log(pc.green(`\nStarting Claude Code for task #${taskId}: ${taskTitle}`));
|
|
88
|
+
if (yolo) {
|
|
89
|
+
console.log(pc.yellow('Mode: YOLO (accepting edits without confirmation)'));
|
|
90
|
+
}
|
|
91
|
+
else {
|
|
92
|
+
console.log(pc.dim('Mode: Plan (will ask for approval before making changes)'));
|
|
93
|
+
}
|
|
88
94
|
console.log(pc.dim(`Directory: ${cwd}\n`));
|
|
89
95
|
// Build initial prompt
|
|
90
96
|
const initialPrompt = [
|
|
@@ -97,11 +103,15 @@ export async function launchClaude(options) {
|
|
|
97
103
|
'2. Use `add_note` for important decisions',
|
|
98
104
|
'3. Call `complete_task` when done or `abandon_task` if stopping early',
|
|
99
105
|
].join('\n');
|
|
106
|
+
// Build Claude args
|
|
107
|
+
const claudeArgs = [
|
|
108
|
+
'--permission-mode', yolo ? 'acceptEdits' : 'plan',
|
|
109
|
+
initialPrompt,
|
|
110
|
+
];
|
|
100
111
|
// Launch Claude Code in interactive mode
|
|
101
|
-
// Pass the prompt as an argument (not --print which is non-interactive)
|
|
102
112
|
// Pass API key so MCP server gets it
|
|
103
113
|
try {
|
|
104
|
-
await execa('claude',
|
|
114
|
+
await execa('claude', claudeArgs, {
|
|
105
115
|
cwd,
|
|
106
116
|
stdio: 'inherit',
|
|
107
117
|
env: {
|