mirror of
https://github.com/junegunn/fzf.git
synced 2025-11-19 09:03:43 -05:00
Updated Examples (markdown)
10
Examples.md
10
Examples.md
@@ -62,16 +62,16 @@ Table of Contents
|
|||||||
# Works only with zsh
|
# Works only with zsh
|
||||||
# Examples:
|
# Examples:
|
||||||
# f mv # To move files. You can write the destination after selecting the files.
|
# f mv # To move files. You can write the destination after selecting the files.
|
||||||
# f 'echo Selected: '
|
# f 'echo Selected:'
|
||||||
# f 'echo Selected music: ' --extention mp3
|
# f 'echo Selected music:' --extention mp3
|
||||||
# fc rm # To rm files in current directory
|
# fm rm # To rm files in current directory
|
||||||
f() {
|
f() {
|
||||||
sels=( "${(@f)$(fd "${fd_default[@]}" "${@:2}"|fz)}" )
|
sels=( "${(@f)$(fd "${fd_default[@]}" "${@:2}"|fz)}" )
|
||||||
test -n "$sels" && print -z -- "$1${sels[@]:q:q}"
|
test -n "$sels" && print -z -- "$1 ${sels[@]:q:q}"
|
||||||
}
|
}
|
||||||
|
|
||||||
# Like f, but not recursive.
|
# Like f, but not recursive.
|
||||||
fc() f "$@" --max-depth 1
|
fm() f "$@" --max-depth 1
|
||||||
```
|
```
|
||||||
|
|
||||||
### Opening files
|
### Opening files
|
||||||
|
|||||||
Reference in New Issue
Block a user