m/fzf
1
0
mirror of https://github.com/junegunn/fzf.git synced 2025-11-15 14:53:47 -05:00

Add exclude-current action

https://github.com/junegunn/fzf/pull/4231#issuecomment-2646063208
This commit is contained in:
Junegunn Choi
2025-02-09 13:37:22 +09:00
parent 67dd7e1923
commit 1be1991299
4 changed files with 79 additions and 12 deletions

View File

@@ -585,6 +585,7 @@ const (
actHideHeader
actBell
actExclude
actExcludeCurrent
)
func (a actionType) Name() string {
@@ -4926,6 +4927,12 @@ func (t *Terminal) Loop() error {
}
}
changed = true
case actExcludeCurrent:
if item := t.currentItem(); item != nil {
denylist = append(denylist, item.Index())
t.deselectItem(item)
changed = true
}
case actExecute, actExecuteSilent:
t.executeCommand(a.a, false, a.t == actExecuteSilent, false, false, "")
case actExecuteMulti: