nix/module/common/bash/module/Tmp.sh
2024-03-04 03:04:57 +03:00

17 lines
234 B
Bash

# CD into host's primary tmp dir.
function tmp() {
local host="${HOSTNAME}"
local tmp_path
case "${host}" in
"desktop"|"home")
tmp_path="/storage/hot/tmp"
;;
*)
tmp_path="${HOME}/tmp"
;;
esac
cd "${tmp_path}"
}