tmp : add tmp.

This commit is contained in:
Dmitry Voronin 2023-11-28 02:34:58 +03:00
parent cc0158fed3
commit f9523f27f2
2 changed files with 23 additions and 0 deletions

View file

@ -631,6 +631,12 @@ Command|Description
---|---
`tsize`|Prints terminal size.
## Tmp.
Command|Description
---|---
`tmp`|CD into host's primary tmp dir.
## Tmux.
Command|Description

View file

@ -0,0 +1,17 @@
# CD into host's primary tmp dir.
tmp()
{
local host="${HOSTNAME}"
local tmp_path
case "${host}" in
"desktop"|"home")
tmp_path="/var/mnt/storage/hot/tmp"
;;
*)
tmp_path="${HOME}/tmp"
;;
esac
cd "${tmp_path}"
}