From: Duy Nguyen Date: Fri, 23 Feb 2018 10:11:18 GMT Subject: Re: [PATCH 1/2] parse-options: expand $HOME on filename options Message-ID: In-Reply-To: <87606pf8kg.fsf@evledraar.gmail.com> On Thu, Feb 22, 2018 at 8:38 PM, Ævar Arnfjörð Bjarmason wrote: > Ah I see, so you're doing "git init --template=~/". > > ... > > I wonder if the consistency with the tab completion wouldn't be better > done by teaching the tab completion to just expand --template=~/ to > e.g. --template=/home/duy/. > > On my (Debian) system doing e.g.: > > echo $HOME/bin/ > > Will expand to: > > echo /home/avar/bin/ > > Maybe we could intercept that in the completion and ~ to the value of > $HOME. Yeah that's what I had in mind (though I still have no idea if it's hard to do). Let's drop this series then. I'll keep this thing in my backlog and hopefully will fix it soon. I'll have to read git-completion.bash carefully for another series anyway. And I have a feeling that "git --completion-helper" needs to tell git-completion.bash "this argument takes a path" before we start to expand stuff. -- Duy