Zsh Mailing List Archive
Messages sorted by: Reverse Date, Date, Thread, Author

Re: Overriding "builtin"



On Mon, Aug 29, 2022 at 1:42 PM Zach Riggle <zachriggle@xxxxxxxxx> wrote:
>
> Why does "=sudo" do the correct thing (assuming a sane $PATH, and executes /usr/bin/sudo), but "=/usr/bin/sudo" does the wrong thing (i.e., execute the function)?

On my Ubuntu at least, =sudo is /bin/sudo not /usr/bin/sudo ... I
suspect if /usr/bin preceded /bin in $PATH, you would not see the
above behavior.  I certainly can't reproduce similar behavior when
using a function named /bin/echo to attempt it.




Messages sorted by: Reverse Date, Date, Thread, Author