2020-11-04 02:03:20 +03:00
|
|
|
#!/bin/sh
|
2021-12-04 21:57:51 +03:00
|
|
|
|
2022-11-08 21:27:59 +03:00
|
|
|
. $HOME/.profile
|
|
|
|
|
2021-12-04 21:57:51 +03:00
|
|
|
q(){
|
|
|
|
echo $SHLVL - 1 | bc
|
|
|
|
exit
|
|
|
|
}
|
|
|
|
|
2022-11-08 21:27:59 +03:00
|
|
|
tmpcdfile=`mktemp`
|
|
|
|
|
|
|
|
c() {
|
|
|
|
oldpwd=`pwd`
|
|
|
|
if command cd $@ && test -n $1 ; then
|
|
|
|
cat $CDHIST > $tmpcdfile
|
|
|
|
{ pwd ; goblin cat $tmpcdfile ; } | \
|
|
|
|
sed $CDHISTMAX'q' | \
|
|
|
|
goblin uniq -U > $CDHIST
|
|
|
|
fi
|
|
|
|
pwd
|
|
|
|
}
|
|
|
|
|
|
|
|
l() {
|
|
|
|
ls $@
|
|
|
|
}
|
|
|
|
|
|
|
|
la() {
|
|
|
|
ls -al $@
|
|
|
|
}
|
|
|
|
|
|
|
|
cds() {
|
|
|
|
acds | sed 10q | goblin quote | nl
|
|
|
|
}
|
|
|
|
|
|
|
|
acds() {
|
|
|
|
cat $CDHIST
|
|
|
|
}
|
|
|
|
|
|
|
|
bcd() {
|
|
|
|
num=$1
|
|
|
|
if test "$1" = "" ; then
|
|
|
|
num=1
|
|
|
|
fi
|
|
|
|
|
|
|
|
backcd=`sed -n $num'p' "$CDHIST"`
|
|
|
|
|
|
|
|
echo $backcd
|
|
|
|
command cd "$backcd"
|
|
|
|
}
|
|
|
|
|
|
|
|
PS1=$PROMPT
|
|
|
|
|
2020-11-04 02:24:45 +03:00
|
|
|
test -r "$LOGIN" && . "$LOGIN"
|
|
|
|
test -r "$SETENV" && . "$SETENV" && setenv sh
|
2022-11-08 21:27:59 +03:00
|
|
|
|
|
|
|
|