@damper/cli 0.5.14 → 0.5.15

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/index.js CHANGED
@@ -5,7 +5,7 @@ import { statusCommand } from './commands/status.js';
5
5
  import { cleanupCommand } from './commands/cleanup.js';
6
6
  import { setupCommand } from './commands/setup.js';
7
7
  import { releaseCommand } from './commands/release.js';
8
- const VERSION = '0.5.14';
8
+ const VERSION = '0.5.15';
9
9
  function showHelp() {
10
10
  console.log(`
11
11
  ${pc.bold('@damper/cli')} - Agent orchestration for Damper tasks
@@ -274,26 +274,23 @@ export async function postTaskFlow(options) {
274
274
  }
275
275
  }
276
276
  else if (taskStatus === 'in_progress') {
277
- // Task not completed - offer options
278
- const action = await select({
279
- message: 'Task is still in progress. What would you like to do?',
280
- choices: [
281
- { name: 'Keep for later (resume with npx @damper/cli)', value: 'keep' },
282
- { name: 'Release task and remove worktree', value: 'release' },
283
- ],
277
+ // Task not completed - always release the lock, optionally remove worktree
278
+ console.log(pc.dim('\nReleasing task lock...'));
279
+ try {
280
+ const api = createDamperApi(apiKey);
281
+ await api.abandonTask(taskId, 'Session ended via CLI');
282
+ console.log(pc.green(`✓ Task released back to planned status`));
283
+ }
284
+ catch (err) {
285
+ const error = err;
286
+ console.log(pc.yellow(`Could not release task: ${error.message}`));
287
+ }
288
+ // Ask about worktree cleanup
289
+ const shouldRemove = await confirm({
290
+ message: 'Remove worktree and branch?',
291
+ default: false,
284
292
  });
285
- if (action === 'release') {
286
- // Release the task back to planned
287
- try {
288
- const api = createDamperApi(apiKey);
289
- await api.abandonTask(taskId, 'Released via CLI');
290
- console.log(pc.green(`✓ Task released back to planned status`));
291
- }
292
- catch (err) {
293
- const error = err;
294
- console.log(pc.yellow(`Could not release task: ${error.message}`));
295
- }
296
- // Remove worktree
293
+ if (shouldRemove) {
297
294
  try {
298
295
  await removeWorktreeDir(cwd, projectRoot);
299
296
  console.log(pc.green('✓ Worktree and branch removed\n'));
@@ -304,7 +301,7 @@ export async function postTaskFlow(options) {
304
301
  }
305
302
  }
306
303
  else {
307
- console.log(pc.dim('\nRun `npx @damper/cli` to resume later.\n'));
304
+ console.log(pc.dim('\nWorktree kept. Run `npx @damper/cli cleanup` to remove later.\n'));
308
305
  }
309
306
  }
310
307
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@damper/cli",
3
- "version": "0.5.14",
3
+ "version": "0.5.15",
4
4
  "description": "CLI tool for orchestrating Damper task workflows with Claude Code",
5
5
  "author": "Damper <hello@usedamper.com>",
6
6
  "repository": {