zsh: made cds() mucho-fast-o
This commit is contained in:
parent
1b5f8d6a80
commit
a82459c1d6
1 changed files with 6 additions and 1 deletions
7
.zshrc
7
.zshrc
|
@ -159,7 +159,12 @@
|
||||||
|
|
||||||
# cd search: cd to a directory, given part of its name
|
# cd search: cd to a directory, given part of its name
|
||||||
cds() {
|
cds() {
|
||||||
cd **/*"$1"* && pwd
|
if ! [ -z "$1" ];then
|
||||||
|
cd "$(fd --max-results=1 -t d "$1")" && pwd
|
||||||
|
else
|
||||||
|
echo "$0: no arguments provided"
|
||||||
|
return 1
|
||||||
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
# toggles whether a file or group of files is executable
|
# toggles whether a file or group of files is executable
|
||||||
|
|
Loading…
Add table
Reference in a new issue