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

Re: Bug report: compinit breaks path resolution in case-insensitive file system



On 29 Jul 2018, at 14:43, Leonardo dos Reis Gama <leonardo.reis.gama@xxxxxxxxx> wrote:
>% zsh -fc 'cmd'
>b/Cmd
>
>% zsh -fc 'autoload compinit; compinit; cmd'  # this one is broken
>a/cmd

I bet this is a simpler way to replicate the same thing:

  % mkdir a b; for 1 in a/cmd b/Cmd; install /dev/null $1
  % PATH=/tmp/b:/tmp/a /bin/zsh -fc 'cmd; hash -v'
  cmd=/tmp/b/cmd
  % PATH=/tmp/b:/tmp/a /bin/zsh -fc ': $commands; cmd; hash -v'
  Cmd=/tmp/b/Cmd
  cmd=/tmp/a/cmd

I guess something about how the command hash table is already filled in the
second case. compinit will be calling something that has the same effect. I only
looked at it for a second though

dana



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