home | list info | list archive | date index | thread index

[OCLUG-Tech] two more questions about .gitignore

  now i remember what i was still curious about. first, is there a
defined meaning for .gitignore entries that start with a slash in a
repository's *sub*directories? i perused several dozen .gitignore
files in subdirectories of the kernel tree and didn't notice a single
entry of the form

  /...

the only ones i've seen are in the single, top-level .gitignore. the
man page doesn't seem to explain what that might mean (if anything) in
a lower-level file. is it *supposed* to mean something?

  finally, about the difference between the two entries:

  dirname/
  dirname/*

as i originally understood it, the obvious difference is that the
first entry would represent the *entirety* of the directory, while the
second -- with its standard use of a wildcard -- would explicitly not
match hidden objects, but would match everything else. is that correct
so far?

  *however*, i read something yesterday (and can no longer lay hands
on it) that seemed to suggest one needed to use the second form in
order to allow lower-level .gitignore files to *negate* the
higher-level entries. i had never heard of this -- is it true?

  i think that's everything. for now.

rday

-- 

========================================================================
Robert P. J. Day                                 Ottawa, Ontario, CANADA
                        http://crashcourse.ca

Twitter:                                       http://twitter.com/rpjday
LinkedIn:                               http://ca.linkedin.com/in/rpjday
========================================================================