Re: [PATCH 7/8] ls-files: support --max-depth

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

 



On Fri, Mar 28, 2014 at 8:52 PM, Matthieu Moy
<Matthieu.Moy@xxxxxxxxxxxxxxx> wrote:
> Duy Nguyen <pclouds@xxxxxxxxx> writes:
>
>> I'd rather go with no trailing slash by default and add -F (which
>> seems to be more than just '/')
>
> ... and then add a configuration variable to let users enable it by
> default.
>
> For GNU ls, I have "alias ls='ls -F --color=auto'" in my shell's
> configuration, but I cannot push the analogy by aliasing "git ls"
> because Git doesn't allow aliasing existing commands.

I can do that but I want to push for a general solution instead
of ls-only. How about config key defaults.<cmd>, containing a list of
arguments, that will be prepended to git-<cmd>? Only some commands are
marked to support this by adding USE_DEFAULTS in the array commands[]
in git.c. And "git --no-defaults <cmd>" will ignore defaults.<cmd> (or
"git -c defaults.<cmd>= <cmd>" but it's less obvious). GIT_NO_DEFAULTS
can also be set, which has the same effect for all commands.
-- 
Duy
--
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]