terminal user interface to jujutsu. Focused on speed and clarity
9
fork

Configure Feed

Select the types of activity you want to include in your feed.

added duplicate and undo commands

+19 -9
+19 -9
jj_tui/bin/graph_view.ml
··· 50 50 ; description = "Make a new empty change as a child of the selected rev" 51 51 } 52 52 ; { 53 + key = 'y' 54 + ; description = "Duplicate the current selected commits " 55 + ; cmd = Dynamic (fun () -> Cmd ([ "duplicate" ] @ Vars.get_active_revs ())) 56 + } 57 + ; { key = 'u'; description = "Undo the last operation"; cmd = Cmd [ "undo" ] } 58 + ; { 53 59 key = 'c' 54 60 ; description = 55 61 "Describe this change and start working on a new rev (same as `describe` then \ ··· 272 278 Cmd [ "bookmark"; "delete"; bookmark ] 273 279 |> confirm_prompt 274 280 (Printf.sprintf 275 - "delete the bookmark: '%s' This will also delete it on the \ 276 - remote next \"git push\"." 281 + "delete the bookmark: '%s' This will also delete it on \ 282 + the remote next \"git push\"." 277 283 bookmark)) 278 284 } 279 285 ; { ··· 287 293 Cmd [ "bookmark"; "forget"; bookmark ] 288 294 |> confirm_prompt 289 295 (Printf.sprintf 290 - "forget the bookmark: '%s' . This will not delete it on the \ 291 - remote." 296 + "forget the bookmark: '%s' . This will not delete it on \ 297 + the remote." 292 298 bookmark)) 293 299 } 294 300 ; { ··· 297 303 ; cmd = 298 304 bookmark_select_prompt 299 305 branches_no_remote 300 - "Select the bookmark to rename (only local/tracked bookmarks are shown)" 306 + "Select the bookmark to rename (only local/tracked bookmarks are \ 307 + shown)" 301 308 (fun curr_name -> 302 309 Prompt ("New bookmark name", [ "bookmark"; "rename"; curr_name ])) 303 310 } ··· 311 318 branches_no_remote 312 319 ("Select the bookmark to set to rev: " ^ rev) 313 320 (fun bookmark -> 314 - Cmd [ "bookmark"; "set"; "-r"; get_hovered_rev (); "-B"; bookmark ])) 321 + Cmd 322 + [ 323 + "bookmark"; "set"; "-r"; get_hovered_rev (); "-B"; bookmark 324 + ])) 315 325 } 316 326 ; { 317 327 key = 't' ··· 320 330 bookmark_select_prompt 321 331 branches_remotes_not_tracked 322 332 "Select the bookmark to begin tracking" 323 - (fun bookmark -> Cmd [ "bookmark"; "track"; bookmark ]) 333 + (fun bookmark -> Cmd [ "bookmark"; "track"; bookmark ]) 324 334 } 325 335 ; { 326 336 key = 'u' ··· 329 339 bookmark_select_prompt 330 340 branches_remotes_tracked 331 341 "Select the bookmark to untrack" 332 - (fun bookmark -> Cmd [ "bookmark"; "untrack"; bookmark ]) 342 + (fun bookmark -> Cmd [ "bookmark"; "untrack"; bookmark ]) 333 343 } 334 344 ] 335 345 } ··· 437 447 (if Focus.peek_has_focus focus 438 448 then Show_view.(push_status (Graph_preview (Vars.get_hovered_rev ())))); 439 449 [%log debug "Hovered revision: '%s'" (Global_vars.get_unique_id hovered)]; 440 - Global_funcs.update_views_async ();) 450 + Global_funcs.update_views_async ()) 441 451 ~custom_handler:(fun ~selected ~selectable_items key -> handleKeys key) 442 452 in 443 453 let final_ui =