When running 'git archive', the .gitattributes file is used to determine
paths that should be ignored when building the archive by using
'export-ignore'.
But it would be useful to include certain sub-paths in the ignored path.
For example, say I have folders like these
/all_useful # this entire sub directory is needed
in the archive
/mostly_unuseful # there are many sub directories in
here to ignore
/mostly_unuseful/needed_a # but these specific sub directories are
desired in the archive
/mostly_unuseful/needed_b
The git-attribute document says a dash '-' prefix should unset the
attribute. It should work with 'export-ignore'
So if I want for example '/mostly_unuseful/needed_a' in my archive, I
should be able to specify that
in my .gitattributes file like this:
/mostly_unuseful export-ignore # do not archive
/mostly_unuseful/needed_a -export-ignore # do add to archive
/mostly_unuseful/needed_b -export-ignore # do add to archive
Thank you