feat: j dotfiles completion
This commit is contained in:
parent
fc8f802133
commit
fceb26bc0b
2 changed files with 2 additions and 2 deletions
|
@ -26,7 +26,7 @@ alias watch='coloralias watch -c -- '
|
|||
alias xargs='xargs '
|
||||
|
||||
function j() {
|
||||
local dests=("${(@f)$(find . -name "$1*" -mount -type d 2> /dev/null)}")
|
||||
local dests=("${(@f)$(find . -mount -name "$1*" -type d 2> /dev/null)}")
|
||||
local dest="${dests:-$1}"
|
||||
|
||||
[ -n "${dests[2]}" ] && dest="$(printf '%s\n' "${dests[@]}" | fzf)"
|
||||
|
|
|
@ -1,3 +1,3 @@
|
|||
#compdef j
|
||||
|
||||
_arguments "1: :(**/"$1")"
|
||||
_arguments "1: :($(find . -mount -name "$1*" -type d -printf "'%P' " 2> /dev/null))"
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue