From caa906ba2d33e9ebdad5e34f778ad20808ee6d99 Mon Sep 17 00:00:00 2001 From: kirawi <67773714+kirawi@users.noreply.github.com> Date: Thu, 4 Jan 2024 12:34:29 -0500 Subject: [PATCH] wip --- book/src/generated/typable-cmd.md | 2 ++ helix-core/src/transaction.rs | 4 +--- helix-term/src/commands/typed.rs | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/book/src/generated/typable-cmd.md b/book/src/generated/typable-cmd.md index f4fcb6f6200e5..647597651e0b3 100644 --- a/book/src/generated/typable-cmd.md +++ b/book/src/generated/typable-cmd.md @@ -86,3 +86,5 @@ | `:clear-register` | Clear given register. If no argument is provided, clear all registers. | | `:redraw` | Clear and re-render the whole UI | | `:move` | Move the current buffer and its corresponding file to a different path | +| `:history-reload` | Prepends undofile history to current history. | +| `:delete-undofile` | Delete undofile associated with the currently focused document | diff --git a/helix-core/src/transaction.rs b/helix-core/src/transaction.rs index 06d32bffb0668..c34aedc0aa5d3 100644 --- a/helix-core/src/transaction.rs +++ b/helix-core/src/transaction.rs @@ -408,9 +408,7 @@ impl ChangeSet { debug_assert!(old_pos <= **pos, "Reverse Iter across changeset works"); continue 'outer; } - let Some(new_pos) = $map(**pos, *assoc) else { - break; - }; + let Some(new_pos) = $map(**pos, *assoc) else { break; }; **pos = new_pos; positions.next(); } diff --git a/helix-term/src/commands/typed.rs b/helix-term/src/commands/typed.rs index 4f3c8acc26709..2bd6c0fb9a18c 100644 --- a/helix-term/src/commands/typed.rs +++ b/helix-term/src/commands/typed.rs @@ -3125,7 +3125,7 @@ pub const TYPABLE_COMMAND_LIST: &[TypableCommand] = &[ // Not named reload-history so people don't accidentally call delete-undofile name: "history-reload", aliases: &[], - doc: "Reload the history for the buffer from its corresponding undofile", + doc: "Prepends undofile history to current history.", fun: reload_undofile, signature: CommandSignature::none(), },