kshutils/j
Adolfo Perez Alvarez bf38c7f42c Notify pwd change via osc escape codes
The `osc` command is available in the `miscutils` project.
2024-06-17 12:05:01 +02:00

16 lines
238 B
Plaintext

function j
{
typeset da
(( $# == 0 )) && diralias && return 0
da=$(diralias $1)
if print $da | grep '^!' >/dev/null
then
if ! da=$(eval $(print "$da" | sed 's/^!//') 2>/dev/null)
then
return 65
fi
fi
'cd' "$da"
osc pwd
}