a,sd,x,..,...

This commit is contained in:
Marc Beninca 2024-11-16 14:58:58 +01:00
parent e73163d2d3
commit 95f52f32eb
Signed by: marc.beninca
GPG key ID: 9C7613450C80C24F

View file

@ -1,32 +1,27 @@
# change current directory to its parent
alias ..="\
cd \
.. \
"
# change current directory to its parent’s parent
alias ...="\
cd \
../.. \
"
# shorten alias # shorten alias
alias a="\ a() {
alias \ alias \
" "${@}"
}
# swap directory (current ↔ previous) # swap directory (current ↔ previous)
alias sd="\ sd() {
cd \ cd - || return
- \ }
"
# import source file
alias src="\
. \
"
# exit terminal # exit terminal
alias x="\ x() {
exit \ exit \
" "${@}"
}
# back
# shellcheck disable=SC3033
..() {
cd ..
}
# shellcheck disable=SC3033
...() {
cd ../..
}