git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* gitignore excludes too much
@ 2009-01-13 13:30 Jan Engelhardt
  2009-01-13 17:36 ` Michael J Gruber
  0 siblings, 1 reply; 2+ messages in thread
From: Jan Engelhardt @ 2009-01-13 13:30 UTC (permalink / raw)
  To: git

Hi,


I noticed that having "*.d" in .gitignore ignores files that would start 
with a dot, such as ".main.o.d". This is against Unix shell behavior;
but maybe it's a feature rather than a bug?
In case of latter, please fix :-)


Jan

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: gitignore excludes too much
  2009-01-13 13:30 gitignore excludes too much Jan Engelhardt
@ 2009-01-13 17:36 ` Michael J Gruber
  0 siblings, 0 replies; 2+ messages in thread
From: Michael J Gruber @ 2009-01-13 17:36 UTC (permalink / raw)
  To: Jan Engelhardt; +Cc: git

Jan Engelhardt venit, vidit, dixit 01/13/09 14:30:
> Hi,
> 
> 
> I noticed that having "*.d" in .gitignore ignores files that would start 
> with a dot, such as ".main.o.d". This is against Unix shell behavior;
> but maybe it's a feature rather than a bug?
> In case of latter, please fix :-)

git uses fnmatch with the last option (flags) being either 0 (for most
purposes) or FNM_PATHNAME (leading /), but never with FNM_PERIOD.

Think "sh with dotglob set" ;)

Since dotfiles tend to be the ones which are not tracked this behaviour
is the more practical one (compared to using FNM_PERIOD and forcing the
typical user to write two patterns).

Cheers,
Michael

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2009-01-13 17:37 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-01-13 13:30 gitignore excludes too much Jan Engelhardt
2009-01-13 17:36 ` Michael J Gruber

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).