Zsh Mailing List Archive
Messages sorted by:
Reverse Date,
Date,
Thread,
Author
Re: zsh: correct 'sudo' to '_sudo' [nyae]?
- X-seq: zsh-users 4572
- From: "Bart Schaefer" <schaefer@xxxxxxxxxxxxxxxx>
- To: Hannu Koivisto <azure@xxxxxx>
- Subject: Re: zsh: correct 'sudo' to '_sudo' [nyae]?
- Date: Wed, 9 Jan 2002 17:34:32 +0000
- Cc: zsh-users@xxxxxxxxxx
- In-reply-to: <87itaecoeu.fsf@xxxxxxxxxxxxxxxx>
- Mailing-list: contact zsh-users-help@xxxxxxxxxx; run by ezmlm
- References: <87ofkvlh37.fsf@xxxxxxxxxxxxxxxx> <1020106030307.ZM7583@xxxxxxxxxxxxxxxxxxxxxxx> <87itaecoeu.fsf@xxxxxxxxxxxxxxxx>
On Jan 7, 2:54pm, Hannu Koivisto wrote:
} Subject: Re: zsh: correct 'sudo' to '_sudo' [nyae]?
}
} > On Dec 19, 11:00am, Hannu Koivisto wrote:
} >}
} >} I always get this message when I start a new shell (whether by
} >} logging to a system or by saying "zsh" when I'm logged on) and try
} >} to run sudo even though sudo is in path.
}
} > Does "rehash -f" (both empty the command hash and refill it again) help?
}
} No.
}
} > Do you use the HASH_LIST_ALL option?
}
} I don't use it but I tried setting it and it changed nothing.
OK, that means there can only be one other reason for this happening:
the directory containing `sudo' is not readable. That is, it has execute
permission set so that by giving the full path to `sudo' you are allowed
to execute the file, but an `ls' on that directory would deny permission.
In this event, `which' searches for and adds to the hash table the single
command by full name, and therefore succeeds, whereas the spell checker
and `rehash -f' try to examine all names in the directory and therefore
fail.
--
Bart Schaefer Brass Lantern Enterprises
http://www.well.com/user/barts http://www.brasslantern.com
Zsh: http://www.zsh.org | PHPerl Project: http://phperl.sourceforge.net
Messages sorted by:
Reverse Date,
Date,
Thread,
Author