From bbc7125bc2ff7d0f5041d9504ddc1ac408824137 Mon Sep 17 00:00:00 2001 From: Jonathan Warykowski Date: Fri, 24 Jul 2026 21:25:25 +1000 Subject: [PATCH] feat: archive an item from the picker Adds an 'archive' action (whole items only) that runs shepherd archive , matching the board's C key. --- README.md | 3 ++- lua/shepherd/init.lua | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index 4b64c27..d722451 100644 --- a/README.md +++ b/README.md @@ -72,7 +72,8 @@ return { - `:ShepherdList` — pick an item (`vim.ui.select`), then act on it: toggle done/undone, **edit** (a pre-filled quick-add line — text, `@category`, `!priority`, `due:`, `defer:`, `link:`, `note:`), set a **status**, add a - **subtask**, **rm**, or **open link** when it has one. Subtasks show indented + **subtask**, **archive** it (whole items only), **rm**, or **open link** when + it has one. Subtasks show indented under their parent and take the same actions. Uses whatever `vim.ui.select` UI you have (dressing, snacks, telescope-ui-select), or the built-in menu. - `:ShepherdList work` — pick within a filtered view. `:ShepherdList!` picks diff --git a/lua/shepherd/init.lua b/lua/shepherd/init.lua index 8c515fe..6636668 100644 --- a/lua/shepherd/init.lua +++ b/lua/shepherd/init.lua @@ -318,6 +318,7 @@ function M.pick(filter, all) local actions = { toggle, "edit", "status", "rm" } if not choice._sub then actions[#actions + 1] = "subtask" + actions[#actions + 1] = "archive" end if choice.link and choice.link ~= "" then actions[#actions + 1] = "open link"