@@ -29,29 +29,29 @@ pub enum CaptureSubcommand {
2929 /// Initialize captures manually
3030 Init ,
3131
32- /// Restore workspace to a checkpoint
32+ /// Restore workspace to a capture
3333 #[ command(
34- about = "Restore workspace to a checkpoint " ,
35- long_about = r#"Restore files to a checkpoint <tag>. If <tag> is omitted, you'll pick one interactively.
34+ about = "Restore workspace to a capture " ,
35+ long_about = r#"Restore files to a capture <tag>. If <tag> is omitted, you'll pick one interactively.
3636
3737Default mode:
3838 • Restores tracked file changes
39- • Keeps new files created after the checkpoint
39+ • Keeps new files created after the capture
4040
4141With --hard:
42- • Exactly matches the checkpoint state
43- • Removes files created after the checkpoint "#
42+ • Exactly matches the capture state
43+ • Removes files created after the capture "#
4444 ) ]
4545 Restore {
46- /// Checkpoint tag (e.g., 3 or 3.1). Leave empty to select interactively.
46+ /// Capture tag (e.g., 3 or 3.1). Leave empty to select interactively.
4747 tag : Option < String > ,
4848
49- /// Exactly match checkpoint state (removes newer files)
49+ /// Exactly match capture state (removes newer files)
5050 #[ arg( long) ]
5151 hard : bool ,
5252 } ,
5353
54- /// List all checkpoints
54+ /// List all captures
5555 List {
5656 /// Limit number of results shown
5757 #[ arg( short, long) ]
@@ -61,18 +61,18 @@ With --hard:
6161 /// Delete the shadow repository
6262 Clean ,
6363
64- /// Show details of a checkpoint
64+ /// Show details of a capture
6565 Expand {
66- /// Checkpoint tag to expand
66+ /// Capture tag to expand
6767 tag : String ,
6868 } ,
6969
70- /// Show differences between checkpoints
70+ /// Show differences between captures
7171 Diff {
72- /// First checkpoint tag
72+ /// First capture tag
7373 tag1 : String ,
7474
75- /// Second checkpoint tag (defaults to current state)
75+ /// Second capture tag (defaults to current state)
7676 #[ arg( required = false ) ]
7777 tag2 : Option < String > ,
7878 } ,
@@ -94,7 +94,10 @@ impl CaptureSubcommand {
9494 if session. conversation . capture_manager . is_some ( ) {
9595 execute ! (
9696 session. stderr,
97- style:: Print ( "✓ Captures are already enabled for this session\n " . blue( ) )
97+ style:: Print (
98+ "✓ Captures are already enabled for this session! Use /capture list to see current captures.\n "
99+ . blue( )
100+ )
98101 ) ?;
99102 } else {
100103 let path = get_shadow_repo_dir ( os, session. conversation . conversation_id ( ) . to_string ( ) )
@@ -110,7 +113,7 @@ impl CaptureSubcommand {
110113 execute ! (
111114 session. stderr,
112115 style:: Print (
113- format!( "✓ Captures enabled ( {:.2}s)\n " , start. elapsed( ) . as_secs_f32( ) )
116+ format!( "✓ Captures are enabled! (took {:.2}s)\n " , start. elapsed( ) . as_secs_f32( ) )
114117 . blue( )
115118 . bold( )
116119 )
@@ -145,7 +148,7 @@ impl CaptureSubcommand {
145148 // Interactive selection
146149 match gather_turn_captures ( & manager) {
147150 Ok ( entries) => {
148- if let Some ( idx) = select_capture ( & entries, "Select checkpoint to restore:" ) {
151+ if let Some ( idx) = select_capture ( & entries, "Select capture to restore:" ) {
149152 Ok ( entries[ idx] . tag . clone ( ) )
150153 } else {
151154 Err ( ( ) )
@@ -172,7 +175,7 @@ impl CaptureSubcommand {
172175 Ok ( _) => {
173176 execute ! (
174177 session. stderr,
175- style:: Print ( format!( "✓ Restored to checkpoint {}\n " , tag) . blue( ) . bold( ) )
178+ style:: Print ( format!( "✓ Restored to capture {}\n " , tag) . blue( ) . bold( ) )
176179 ) ?;
177180 session. conversation . capture_manager = Some ( manager) ;
178181 } ,
@@ -214,9 +217,18 @@ impl CaptureSubcommand {
214217 } ) ;
215218 } ;
216219
220+ // Print the path that will be deleted
221+ execute ! (
222+ session. stderr,
223+ style:: Print ( format!( "Deleting: {}\n " , manager. shadow_repo_path. display( ) ) )
224+ ) ?;
225+
217226 match manager. cleanup ( os) . await {
218227 Ok ( ( ) ) => {
219- execute ! ( session. stderr, style:: Print ( "✓ Shadow repository deleted.\n " . bold( ) ) ) ?;
228+ execute ! (
229+ session. stderr,
230+ style:: Print ( "✓ Deleted shadow repository for this session.\n " . bold( ) )
231+ ) ?;
220232 } ,
221233 Err ( e) => {
222234 session. conversation . capture_manager = Some ( manager) ;
@@ -270,7 +282,13 @@ impl CaptureSubcommand {
270282 if tag1 != "HEAD" && !manager. tag_index . contains_key ( & tag1) {
271283 execute ! (
272284 session. stderr,
273- style:: Print ( format!( "⚠ Checkpoint '{}' not found\n " , tag1) . yellow( ) )
285+ style:: Print (
286+ format!(
287+ "⚠ Capture '{}' not found! Use /capture list to see available captures\n " ,
288+ tag1
289+ )
290+ . yellow( )
291+ )
274292 ) ?;
275293 return Ok ( ChatState :: PromptUser {
276294 skip_printing_tools : true ,
@@ -280,15 +298,21 @@ impl CaptureSubcommand {
280298 if tag2 != "HEAD" && !manager. tag_index . contains_key ( & tag2) {
281299 execute ! (
282300 session. stderr,
283- style:: Print ( format!( "⚠ Checkpoint '{}' not found\n " , tag2) . yellow( ) )
301+ style:: Print (
302+ format!(
303+ "⚠ Capture '{}' not found! Use /capture list to see available captures\n " ,
304+ tag2
305+ )
306+ . yellow( )
307+ )
284308 ) ?;
285309 return Ok ( ChatState :: PromptUser {
286310 skip_printing_tools : true ,
287311 } ) ;
288312 }
289313
290314 let header = if tag2 == "HEAD" {
291- format ! ( "Changes since checkpoint {}:\n " , tag1)
315+ format ! ( "Changes since capture {}:\n " , tag1)
292316 } else {
293317 format ! ( "Changes from {} to {}:\n " , tag1, tag2)
294318 } ;
@@ -410,7 +434,7 @@ fn expand_capture(manager: &CaptureManager, output: &mut impl Write, tag: &str)
410434 let Some ( & idx) = manager. tag_index . get ( tag) else {
411435 execute ! (
412436 output,
413- style:: Print ( format!( "⚠ Checkpoint '{}' not found\n " , tag) . yellow( ) )
437+ style:: Print ( format!( "⚠ capture '{}' not found\n " , tag) . yellow( ) )
414438 ) ?;
415439 return Ok ( ( ) ) ;
416440 } ;
0 commit comments