mirror of
https://github.com/prdlk/television.git
synced 2026-11-02 13:12:51 +00:00
Import from root chezmoi source
This commit is contained in:
commit
c8c8c9a000
77 files changed
+2443
No files matched your search
@@ -0,0 +1,24 @@
|
||||
[metadata]
|
||||
name = "git-deletions"
|
||||
description = "A channel to list files which were deleted from the Git repository"
|
||||
requirements = ["git", "rg", "bat"]
|
||||
|
||||
[source]
|
||||
command = "git log --diff-filter=D --summary | rg 'delete mode \\d+' -r '' --trim"
|
||||
|
||||
[preview]
|
||||
command = ["git show \"$(git rev-list -n1 HEAD -- '{}')^:{}\" | bat -n --color always --file-name '{}'", "git show --summary \"$(git rev-list -n1 HEAD -- '{}')\""]
|
||||
|
||||
[keybindings]
|
||||
enter = "actions:print_commit"
|
||||
ctrl-r = "actions:restore_file"
|
||||
|
||||
[actions.print_commit]
|
||||
description = "Print the latest commit where file was deleted"
|
||||
command = "echo \"$(git rev-list -n1 HEAD -- {})\""
|
||||
mode = "execute"
|
||||
|
||||
[actions.restore_file]
|
||||
description = "Restore the selected file"
|
||||
command = "git checkout \"$(git rev-list -n1 HEAD -- {})^\" -- {}"
|
||||
|
||||
Reference in new issue
Block a user