Silence error messages from cut

darcs-hash:20050924021157-ac50b-296a425d89aea044fe8dc9991d74fe0cc9761382.gz
This commit is contained in:
axel 2005-09-24 12:11:57 +10:00
parent 79b8ff535e
commit 495c83a26c

View file

@ -212,7 +212,7 @@ function prompt_pwd -d "Print the current working directory, ellipsise it if it
set ellipsis \u2026
end
end
printf %s%s $ellipsis (echo $wd|cut -c (echo $len-$max_width-1|bc)-)
printf %s%s $ellipsis (echo $wd|cut -c (echo $len-$max_width-1|bc)- ^/dev/null )
else
echo $wd
end
@ -226,7 +226,7 @@ function pwd -d "Print working directory"
set out (command pwd $argv)
if echo $out| grep \^$HOME >/dev/null
printf \~
echo $out |cut -b (echo $HOME|wc -c)-
echo $out |cut -b (echo $HOME|wc -c)- ^/dev/null
else
printf "%s\n" $out
end