claude-dev-cli 0.13.0__tar.gz → 0.13.3__tar.gz

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.
Files changed (49) hide show
  1. {claude_dev_cli-0.13.0/src/claude_dev_cli.egg-info → claude_dev_cli-0.13.3}/PKG-INFO +102 -1
  2. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/README.md +100 -0
  3. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/pyproject.toml +2 -1
  4. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/__init__.py +1 -1
  5. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/cli.py +3 -3
  6. claude_dev_cli-0.13.3/src/claude_dev_cli/multi_file_handler.py +732 -0
  7. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3/src/claude_dev_cli.egg-info}/PKG-INFO +102 -1
  8. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli.egg-info/requires.txt +1 -0
  9. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_multi_file_handler.py +193 -0
  10. claude_dev_cli-0.13.0/src/claude_dev_cli/multi_file_handler.py +0 -348
  11. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/LICENSE +0 -0
  12. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/MANIFEST.in +0 -0
  13. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/setup.cfg +0 -0
  14. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/commands.py +0 -0
  15. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/config.py +0 -0
  16. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/context.py +0 -0
  17. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/core.py +0 -0
  18. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/history.py +0 -0
  19. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/input_sources.py +0 -0
  20. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/path_utils.py +0 -0
  21. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/plugins/__init__.py +0 -0
  22. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/plugins/base.py +0 -0
  23. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/plugins/diff_editor/__init__.py +0 -0
  24. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/plugins/diff_editor/plugin.py +0 -0
  25. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/plugins/diff_editor/viewer.py +0 -0
  26. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/secure_storage.py +0 -0
  27. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/template_manager.py +0 -0
  28. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/templates.py +0 -0
  29. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/toon_utils.py +0 -0
  30. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/usage.py +0 -0
  31. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/warp_integration.py +0 -0
  32. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli/workflows.py +0 -0
  33. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli.egg-info/SOURCES.txt +0 -0
  34. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli.egg-info/dependency_links.txt +0 -0
  35. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli.egg-info/entry_points.txt +0 -0
  36. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/src/claude_dev_cli.egg-info/top_level.txt +0 -0
  37. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_cli.py +0 -0
  38. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_commands.py +0 -0
  39. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_config.py +0 -0
  40. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_context.py +0 -0
  41. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_core.py +0 -0
  42. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_diff_editor.py +0 -0
  43. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_history.py +0 -0
  44. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_input_sources.py +0 -0
  45. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_path_utils.py +0 -0
  46. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_secure_storage.py +0 -0
  47. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_template_manager.py +0 -0
  48. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_toon_utils.py +0 -0
  49. {claude_dev_cli-0.13.0 → claude_dev_cli-0.13.3}/tests/test_usage.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: claude-dev-cli
3
- Version: 0.13.0
3
+ Version: 0.13.3
4
4
  Summary: A powerful CLI tool for developers using Claude AI with multi-API routing, test generation, code review, and usage tracking
5
5
  Author-email: Julio <thinmanj@users.noreply.github.com>
6
6
  License: MIT
@@ -29,6 +29,7 @@ Requires-Dist: pydantic>=2.0.0
29
29
  Requires-Dist: keyring>=24.0.0
30
30
  Requires-Dist: cryptography>=41.0.0
31
31
  Requires-Dist: pyyaml>=6.0.0
32
+ Requires-Dist: unidiff>=0.7.0
32
33
  Provides-Extra: toon
33
34
  Requires-Dist: toon-format>=0.1.0; extra == "toon"
34
35
  Provides-Extra: plugins
@@ -315,8 +316,108 @@ cdc generate feature --file spec.md --yes # Apply without confirmation
315
316
 
316
317
  # Interactive feature implementation
317
318
  cdc generate feature --description "Add logging" src/ --interactive
319
+
320
+ # Hunk-by-hunk approval (like git add -p) - NEW in v0.13.1
321
+ cdc generate feature -f spec.md
322
+ # At confirmation prompt, type 'patch' to review changes hunk-by-hunk
323
+ # Options: y (yes), n (no), s (skip file), q (quit), help
324
+ ```
325
+
326
+ ### 3.1 Interactive Diff Approval (v0.13.1+)
327
+
328
+ When applying file modifications, you can review and approve changes hunk-by-hunk, similar to `git add -p`:
329
+
330
+ ```bash
331
+ # After generating feature/refactor changes:
332
+ cdc generate feature -f spec.md
333
+
334
+ # At the confirmation prompt:
335
+ Continue? (Y/n/preview/patch/help) patch
336
+
337
+ # For each file:
338
+ File: src/main.py
339
+ Modify file (3 hunk(s))
340
+
341
+ Hunk 1/3:
342
+ [Shows diff with syntax highlighting]
343
+ @@ -10,3 +10,5 @@
344
+ def main():
345
+ - print("old")
346
+ + print("new")
347
+ + logging.info("Started")
348
+
349
+ Apply this hunk? (y/n/s=skip file/q=quit/help) y # Approve this hunk
350
+
351
+ Hunk 2/3:
352
+ [Shows next diff]
353
+ Apply this hunk? (y/n/s=skip file/q=quit/help) n # Skip this hunk
354
+
355
+ Hunk 3/3:
356
+ [Shows final diff]
357
+ Apply this hunk? (y/n/s=skip file/q=quit/help) s # Skip remaining in file
358
+
359
+ # File operations options:
360
+ Create this file? (y/n/s=skip/q=quit) y # For new files
361
+ Delete this file? (y/n/s=skip/q=quit) n # For file deletions
362
+ ```
363
+
364
+ **Options:**
365
+ - `y, yes` - Apply this hunk/file
366
+ - `n, no` - Skip this hunk (keeps original)
367
+ - `s, skip` - Skip remaining hunks in current file
368
+ - `q, quit` - Stop reviewing and apply approved changes so far
369
+ - `edit` - Open files in $EDITOR before applying
370
+ - `save` - Save to custom location
371
+ - `help` - Show help message
372
+
373
+ **Benefits:**
374
+ - Fine-grained control over changes
375
+ - Keep original code for some hunks while applying others
376
+ - Syntax-highlighted diffs for easy review
377
+ - Edit files before applying for manual tweaks
378
+ - Save to custom location without -o flag
379
+ - Safe: only approved hunks are written
380
+
381
+ ### 3.2 Edit and Save Options (v0.13.2+)
382
+
383
+ Before applying changes, you can edit files or save to custom locations:
384
+
385
+ #### Edit in $EDITOR
386
+ ```bash
387
+ cdc generate feature -f spec.md
388
+
389
+ # At confirmation:
390
+ Continue? (Y/n/preview/patch/edit/save/help) edit
391
+
392
+ # Opens each file in your $EDITOR (vi, nano, code, etc.)
393
+ # Make manual adjustments, save and close
394
+ # Changes are applied after editing
318
395
  ```
319
396
 
397
+ #### Save to Custom Location
398
+ ```bash
399
+ cdc generate code -d "REST API" -o /tmp/output
400
+
401
+ # At confirmation:
402
+ Continue? (Y/n/preview/patch/edit/save/help) save
403
+
404
+ # Single file:
405
+ Filename: my-custom-name.py # Save to custom filename
406
+
407
+ # Multiple files:
408
+ Directory: /path/to/output/ # Save entire project elsewhere
409
+ ```
410
+
411
+ **Use Cases:**
412
+ - **Edit**: Make manual tweaks before applying (fix formatting, adjust logic)
413
+ - **Save**: Try changes elsewhere before applying to project
414
+ - **Edit + Preview**: Review, edit, then apply with confidence
415
+ - **Save for later**: Generate code, save it, review offline, apply manually
416
+
417
+ **Environment Variables:**
418
+ - `$EDITOR`: Your preferred editor (e.g., `export EDITOR=nano`)
419
+ - Defaults to `vi` if `$EDITOR` not set
420
+
320
421
  ### 4. Developer Commands
321
422
 
322
423
  ```bash
@@ -264,8 +264,108 @@ cdc generate feature --file spec.md --yes # Apply without confirmation
264
264
 
265
265
  # Interactive feature implementation
266
266
  cdc generate feature --description "Add logging" src/ --interactive
267
+
268
+ # Hunk-by-hunk approval (like git add -p) - NEW in v0.13.1
269
+ cdc generate feature -f spec.md
270
+ # At confirmation prompt, type 'patch' to review changes hunk-by-hunk
271
+ # Options: y (yes), n (no), s (skip file), q (quit), help
272
+ ```
273
+
274
+ ### 3.1 Interactive Diff Approval (v0.13.1+)
275
+
276
+ When applying file modifications, you can review and approve changes hunk-by-hunk, similar to `git add -p`:
277
+
278
+ ```bash
279
+ # After generating feature/refactor changes:
280
+ cdc generate feature -f spec.md
281
+
282
+ # At the confirmation prompt:
283
+ Continue? (Y/n/preview/patch/help) patch
284
+
285
+ # For each file:
286
+ File: src/main.py
287
+ Modify file (3 hunk(s))
288
+
289
+ Hunk 1/3:
290
+ [Shows diff with syntax highlighting]
291
+ @@ -10,3 +10,5 @@
292
+ def main():
293
+ - print("old")
294
+ + print("new")
295
+ + logging.info("Started")
296
+
297
+ Apply this hunk? (y/n/s=skip file/q=quit/help) y # Approve this hunk
298
+
299
+ Hunk 2/3:
300
+ [Shows next diff]
301
+ Apply this hunk? (y/n/s=skip file/q=quit/help) n # Skip this hunk
302
+
303
+ Hunk 3/3:
304
+ [Shows final diff]
305
+ Apply this hunk? (y/n/s=skip file/q=quit/help) s # Skip remaining in file
306
+
307
+ # File operations options:
308
+ Create this file? (y/n/s=skip/q=quit) y # For new files
309
+ Delete this file? (y/n/s=skip/q=quit) n # For file deletions
310
+ ```
311
+
312
+ **Options:**
313
+ - `y, yes` - Apply this hunk/file
314
+ - `n, no` - Skip this hunk (keeps original)
315
+ - `s, skip` - Skip remaining hunks in current file
316
+ - `q, quit` - Stop reviewing and apply approved changes so far
317
+ - `edit` - Open files in $EDITOR before applying
318
+ - `save` - Save to custom location
319
+ - `help` - Show help message
320
+
321
+ **Benefits:**
322
+ - Fine-grained control over changes
323
+ - Keep original code for some hunks while applying others
324
+ - Syntax-highlighted diffs for easy review
325
+ - Edit files before applying for manual tweaks
326
+ - Save to custom location without -o flag
327
+ - Safe: only approved hunks are written
328
+
329
+ ### 3.2 Edit and Save Options (v0.13.2+)
330
+
331
+ Before applying changes, you can edit files or save to custom locations:
332
+
333
+ #### Edit in $EDITOR
334
+ ```bash
335
+ cdc generate feature -f spec.md
336
+
337
+ # At confirmation:
338
+ Continue? (Y/n/preview/patch/edit/save/help) edit
339
+
340
+ # Opens each file in your $EDITOR (vi, nano, code, etc.)
341
+ # Make manual adjustments, save and close
342
+ # Changes are applied after editing
267
343
  ```
268
344
 
345
+ #### Save to Custom Location
346
+ ```bash
347
+ cdc generate code -d "REST API" -o /tmp/output
348
+
349
+ # At confirmation:
350
+ Continue? (Y/n/preview/patch/edit/save/help) save
351
+
352
+ # Single file:
353
+ Filename: my-custom-name.py # Save to custom filename
354
+
355
+ # Multiple files:
356
+ Directory: /path/to/output/ # Save entire project elsewhere
357
+ ```
358
+
359
+ **Use Cases:**
360
+ - **Edit**: Make manual tweaks before applying (fix formatting, adjust logic)
361
+ - **Save**: Try changes elsewhere before applying to project
362
+ - **Edit + Preview**: Review, edit, then apply with confidence
363
+ - **Save for later**: Generate code, save it, review offline, apply manually
364
+
365
+ **Environment Variables:**
366
+ - `$EDITOR`: Your preferred editor (e.g., `export EDITOR=nano`)
367
+ - Defaults to `vi` if `$EDITOR` not set
368
+
269
369
  ### 4. Developer Commands
270
370
 
271
371
  ```bash
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "claude-dev-cli"
7
- version = "0.13.0"
7
+ version = "0.13.3"
8
8
  description = "A powerful CLI tool for developers using Claude AI with multi-API routing, test generation, code review, and usage tracking"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.9"
@@ -35,6 +35,7 @@ dependencies = [
35
35
  "keyring>=24.0.0",
36
36
  "cryptography>=41.0.0",
37
37
  "pyyaml>=6.0.0",
38
+ "unidiff>=0.7.0",
38
39
  ]
39
40
 
40
41
  [project.optional-dependencies]
@@ -9,7 +9,7 @@ Features:
9
9
  - Interactive and single-shot modes
10
10
  """
11
11
 
12
- __version__ = "0.13.0"
12
+ __version__ = "0.13.3"
13
13
  __author__ = "Julio"
14
14
  __license__ = "MIT"
15
15
 
@@ -1270,7 +1270,7 @@ Use proper directory structure and include proper error handling, documentation,
1270
1270
 
1271
1271
  # Confirm or auto-accept
1272
1272
  if not yes and not dry_run:
1273
- if not multi_file.confirm(console):
1273
+ if not multi_file.confirm(console, output_path):
1274
1274
  console.print("[yellow]Cancelled[/yellow]")
1275
1275
  return
1276
1276
 
@@ -1489,7 +1489,7 @@ def gen_feature(
1489
1489
 
1490
1490
  # Confirm or auto-accept
1491
1491
  if not yes:
1492
- if not multi_file.confirm(console):
1492
+ if not multi_file.confirm(console, base_path):
1493
1493
  console.print("[yellow]Cancelled[/yellow]")
1494
1494
  return
1495
1495
 
@@ -1855,7 +1855,7 @@ def refactor(
1855
1855
 
1856
1856
  # Confirm or auto-accept
1857
1857
  if not yes:
1858
- if not multi_file.confirm(console):
1858
+ if not multi_file.confirm(console, base_path):
1859
1859
  console.print("[yellow]Cancelled[/yellow]")
1860
1860
  return
1861
1861