Support j
This commit is contained in:
parent
f7b4e36cc3
commit
9de770c4bc
|
@ -7,10 +7,21 @@ if [ "$PRESERVE_SSH_CWD" = "true" ]; then
|
|||
cd() {
|
||||
if [ -z "$1" ]; then
|
||||
directory=$HOME
|
||||
elif [[ "$1" == "-P" ]] && [ -z $2 ]; then
|
||||
directory="$HOME"
|
||||
option="$1"
|
||||
elif [[ "$1" == "-P" ]]; then
|
||||
directory="$2"
|
||||
option="$1"
|
||||
else
|
||||
directory="$1"
|
||||
fi
|
||||
|
||||
if [ -z "$option" ]; then
|
||||
builtin cd "$directory"
|
||||
else
|
||||
builtin cd "$option" "$directory"
|
||||
fi
|
||||
pwd > $HOME/.config/terminalscwd/$TERMINAL_UUID.cwd
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue