Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Stopping functions breaking
- X-seq: zsh-users 6845
- From: zzapper <david@xxxxxxxxxx>
- To: zsh-users@xxxxxxxxxx
- Subject: Stopping functions breaking
- Date: Mon, 08 Dec 2003 12:25:35 +0000
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- Sender: news <news@xxxxxxxxxxxxx>
Hi
I'm writing a function (see below) which I call such
> pub fred
I want it to cd to any directory beginning fred, if there 0 or more
than 1 matches I wish to carry on in the script.
However whatever I try 0 or no matches breaks the script.
HELP PLEASE
function pub
{
if [ $# -gt 0 ];
then
echo $?
builtin chdir $1* &> /dev/null
echo $?
zzapper
--
vim -c ":%s/^/WhfgTNabgureRIvzSUnpxre/|:%s/[R-T]/ /Ig|:normal ggVGg?"
http://www.vim.org/tips/tip.php?tip_id=305 Best of Vim Tips
Messages sorted by:
Reverse Date,
Date,
Thread,
Author