From: Aaron Schrab Date: Fri, 29 May 2015 13:24:53 GMT Subject: Re: Redirect "git" subcommand to itself? Message-ID: <20150529132453.GA1308@pug.qqx.org> In-Reply-To: <87zj4n4w3t.fsf@gmail.com> At 10:38 +0200 29 May 2015, Christian Neukirchen wrote: >Junio C Hamano writes: > >> * You can help yourself with something like this, I suppose: >> >> [alias] >> git = "!sh -c 'exec git \"$@\"' -" >> >> but I personally feel that it is too ugly to live as part of our >> official suggestion, so please do not send a patch to add it as >> a built-in alias ;-). > >So I thought I was clever, but this didn't work: I've done the same as the original poster a few times myself, so awhile ago I added the following to my .gitconfig file: [alias] git = "!f() { git $@; }; f" And this has worked for me.