Re: Redirect "git" subcommand to itself?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Junio C Hamano <gitster@xxxxxxxxx> writes:

> Christian Neukirchen <chneukirchen@xxxxxxxxx> writes:
>
>> Junio C Hamano <gitster@xxxxxxxxx> 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:
>>
>> % ln -s /usr/bin/git ~/bin/git-git  
>> % git git
>> fatal: cannot handle git as a builtin
>
> Why did you have to do that when I already gave an alias that works?

I was just toying around, and it would have been cute.

> Or didn't the alias work?

It does.  This seems to work just as well, and is easier:

	git = !git

Thanks,
-- 
Christian Neukirchen  <chneukirchen@xxxxxxxxx>  http://chneukirchen.org
--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]