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

Re: [BUG]Filename autocompletion using git-bare repos (--git-dir=... --work-tree=...)



On Tue, Sep 12, 2023 at 10:54 AM eliasghafari <eliasghafari@xxxxxxxxxxx> wrote:
>
> After using <C-x ?> instead of <Tab> (Thanks Bart) and looking at the output I found
> that:
> alias config='git --git-dir ~/.local/share/dotfiles --work-tree ~'
> works perfectly.
> And Jun T's solution of:
> alias config="git --git-dir=$HOME/.local/share/dotfiles --work-tree $HOME"
> Also works I never knew that there was a difference between ' and ".

Given these two definitions that differ only in quotes:

    alias c1="git --git-dir=$HOME/.local/share/dotfiles --work-tree $HOME"
    alias c2='git --git-dir=$HOME/.local/share/dotfiles --work-tree $HOME'

Can you confirm that the following two commands work as expected?

    c1 diff
    c2 diff

Can you furthermore confirm that only the first of the following works
as expected while the second does not?

    c1 diff <TAB>
    c2 diff <TAB>

If so, this indicates a bug in the completion code.

Roman.




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