• don’t eat builtin cd errorlevel in function cd

• fix extglob in function cd_csh to match current error strings
This commit is contained in:
tg 2013-08-22 13:46:46 +00:00
parent 5eb6995d75
commit 75c00ebaae
1 changed files with 3 additions and 3 deletions

View File

@ -1,5 +1,5 @@
# $Id$
# $MirOS: src/bin/mksh/dot.mkshrc,v 1.84 2013/08/10 13:43:50 tg Exp $
# $MirOS: src/bin/mksh/dot.mkshrc,v 1.85 2013/08/22 13:46:46 tg Exp $
#-
# Copyright (c) 2002, 2003, 2004, 2006, 2007, 2008, 2009, 2010,
# 2011, 2012, 2013
@ -105,14 +105,14 @@ function chpwd {
}
chpwd .
function cd {
builtin cd "$@"
builtin cd "$@" || return $?
chpwd "$@"
}
function cd_csh {
local d t=${1/#~/$DIRSTACKBASE}
if ! d=$(builtin cd "$t" 2>&1); then
print -u2 "${1}: ${d##*$t - }."
print -u2 "${1}: ${d##*cd: $t: }."
return 1
fi
cd "$t"