shell/shortcuts
This commit is contained in:
parent
24a931cbfc
commit
51cb88d0d3
2 changed files with 26 additions and 18 deletions
|
@ -1,18 +0,0 @@
|
||||||
# shorten alias
|
|
||||||
a() {
|
|
||||||
alias \
|
|
||||||
"${@}"
|
|
||||||
}
|
|
||||||
|
|
||||||
# swap directory (current ↔ previous)
|
|
||||||
sd() {
|
|
||||||
cd \
|
|
||||||
- ||
|
|
||||||
return
|
|
||||||
}
|
|
||||||
|
|
||||||
# exit terminal
|
|
||||||
x() {
|
|
||||||
exit \
|
|
||||||
"${@}"
|
|
||||||
}
|
|
|
@ -130,6 +130,32 @@ rwx_shell_prompt() {
|
||||||
printf "%b" "${view}"
|
printf "%b" "${view}"
|
||||||
}
|
}
|
||||||
|
|
||||||
|
# ╭───────┬───────────╮
|
||||||
|
# │ shell │ shortcuts │
|
||||||
|
# ╰───────┴───────────╯
|
||||||
|
|
||||||
|
# shorten alias
|
||||||
|
#= a
|
||||||
|
rwx_shell_alias() {
|
||||||
|
alias \
|
||||||
|
"${@}"
|
||||||
|
}
|
||||||
|
|
||||||
|
# swap directory (current ↔ previous)
|
||||||
|
#= sd
|
||||||
|
rwx_shell_swap_directory() {
|
||||||
|
cd \
|
||||||
|
- ||
|
||||||
|
return
|
||||||
|
}
|
||||||
|
|
||||||
|
# exit terminal
|
||||||
|
#= x
|
||||||
|
rwx_shell_exit() {
|
||||||
|
exit \
|
||||||
|
"${@}"
|
||||||
|
}
|
||||||
|
|
||||||
# ╭───────┬──────╮
|
# ╭───────┬──────╮
|
||||||
# │ shell │ main │
|
# │ shell │ main │
|
||||||
# ╰───────┴──────╯
|
# ╰───────┴──────╯
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue