Re: git silently ignores aliases of existing commands

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

 



2009/7/18 Jeff King <peff@xxxxxxxx>:
> On Sat, Jul 18, 2009 at 11:30:25AM +0200, demerphq wrote:
>
>> Yeah it seems reasonable that if its going to be ignored it should not
>> be silently ignored.
>
> I agree that there should be a warning. However, it's hard to do with
> the code structured as it is now; we don't know that a command exists
> as an external command until we try to exec it. And if it succeeds, we
> don't get to execute any more code.
>
> It's certainly possible, but sadly it is more surgery than just
>
>  if (alias_lookup(cmd))
>    warn("you also have an alias defined");
>
>> Especially given that the silentness effectively means there cant be
>> any new git tools added without possible breakage of installed setups.
>
> The silentness makes it harder to diagnose problems, but even with a
> warning, we can break things by creating new commands. If you have an
> alias "foo" and we ship "git-foo" in a newer version of git, your alias
> will just stop working.

That was my point. At least if there were warnings about this the risk
would be mitigated.

cheers,
Yves


-- 
perl -Mre=debug -e "/just|another|perl|hacker/"
--
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]