Re: Relative paths don't work in .gitignore as would be expected.

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

 



+git@xxxxxxxxxxxxxxx, plain text

I would say just use zsh globbing, it has the double star, but it'd
likely too late for that. You'd add a single rule: ignore any files
that are in a directory higher up than the .gitignore where the rule
is found.

Then if you have a git repo in your fs at /git/repo with a
/git/repo/.gitignore you could put /git/repo/*.js, *.js, or ./*.js to
ignore the same thing (the absolute path may or may not bite the
person in the ass when he moves the repo, but that's not our problem),
so those would be equivalent to the current /*.js (give or take the
absolute example). You could do **/*.js the zsh way to start ignoring
things everywhere, equivalent to the current *.js.
/#!/JoePea


On Tue, Feb 10, 2015 at 1:19 AM, /#!/JoePea <trusktr@xxxxxxxxx> wrote:
> I would say just use zsh globbing, it has the double star, but it'd likely
> too late for that. You'd add a single rule: ignore any files that are in a
> directory higher up than the .gitignore where the rule is found.
>
> Then if you have a git repo in your fs at /git/repo with a
> /git/repo/.gitignore you could put /git/repo/*.js, *.js, or ./*.js to ignore
> the same thing (the absolute path may or may not bite the person in the ass
> when he moves the repo, but that's not our problem), so those would be
> equivalent to the current /*.js (give or take the absolute example). You
> could do **/*.js the zsh way to start ignoring things everywhere, equivalent
> to the current *.js.
>
> /#!/JoePea
--
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]