* git-archive ignores export-ignore
@ 2010-01-21 22:13 Todd A. Jacobs
2010-01-22 0:57 ` Junio C Hamano
0 siblings, 1 reply; 3+ messages in thread
From: Todd A. Jacobs @ 2010-01-21 22:13 UTC (permalink / raw)
To: git
Using git 1.6.4.2, the manual page prophesies that:
Files and directories with the attribute export-ignore won't be
added to archive files. See gitattributes(5) for details.
However, various tools seem to be unhappy about this attribute. In
particular, checkout complains about invalid attributes:
$ cat .gitattributes
*.py export-subst
*.html export-subst
juniperxml.cfg export-ignore
$ git checkout juniperxml.cfg
export-ignore is not a valid attribute name: .gitattributes:3
It appears that git-archive doesn't seem to respect the attribute
either. Consider the following example:
cd /tmp
mkdir foo
cd foo
git init
touch foo.sh
echo '*sh' > .gitattributes
git add foo.sh
git add .gitattributes
git commit -m test
git archive HEAD
pax_global_header00006660000000000000000000000064113261226070014512gustar00rootroot0000000000000052 comment=202d78e6a44c7f10bee2ad96a3b2adc80fc33468
.gitattributes000066400000000000000000000000041132612260700137430ustar00rootroot00000000000000*sh
foo.sh000066400000000000000000000000001132612260700121630ustar00rootroot00000000000000
In addition to whatever bugs there might be in reading and applying the
attributes correctly, it would seem that the man page could be a bit
clearer on how and where to apply the attributes.
Assuming PEBKAC for the moment, how can I get the behavior I'm
expecting?
--
"Oh, look: rocks!"
-- Doctor Who, "Destiny of the Daleks"
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: git-archive ignores export-ignore
2010-01-21 22:13 git-archive ignores export-ignore Todd A. Jacobs
@ 2010-01-22 0:57 ` Junio C Hamano
2010-01-22 18:07 ` Todd A. Jacobs
0 siblings, 1 reply; 3+ messages in thread
From: Junio C Hamano @ 2010-01-22 0:57 UTC (permalink / raw)
To: nospam; +Cc: git
"Todd A. Jacobs" <nospam@codegnome.org> writes:
> Using git 1.6.4.2, the manual page prophesies that:
>
> Files and directories with the attribute export-ignore won't be
> added to archive files. See gitattributes(5) for details.
>
> However, various tools seem to be unhappy about this attribute. In
> particular, checkout complains about invalid attributes:
>
> $ cat .gitattributes
> *.py export-subst
> *.html export-subst
> juniperxml.cfg export-ignore
>
> $ git checkout juniperxml.cfg
> export-ignore is not a valid attribute name: .gitattributes:3
$ cat .gitattributes
* whitespace=!indent,trail,space
*.[ch] whitespace=indent,trail,space
*.sh whitespace=indent,trail,space
COPYING export-ignore
$ git checkout COPYING
$ wc -l COPYING
360 COPYING
There is something that is different in my failed attempt to reproduce it
from your problem description, but I cannot tell what it is.
Do you have some garbage character immediately after "e" in "-ignore"?
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: git-archive ignores export-ignore
2010-01-22 0:57 ` Junio C Hamano
@ 2010-01-22 18:07 ` Todd A. Jacobs
0 siblings, 0 replies; 3+ messages in thread
From: Todd A. Jacobs @ 2010-01-22 18:07 UTC (permalink / raw)
To: git
On Thu, Jan 21, 2010 at 04:57:39PM -0800, Junio C Hamano wrote:
> There is something that is different in my failed attempt to reproduce it
> from your problem description, but I cannot tell what it is.
>
> Do you have some garbage character immediately after "e" in "-ignore"?
No, but it turns out that juniperxml.cfg is actually a symlink in this
repository. I'm not sure that should make a difference, but perhaps
that's the missing element in recreating the problem.
I wouldn't think so, because the reason it's a symlink is because I was
unable to get git-archive to ignore the actual file on export, so I
moved it elsewhere and replaced it with a symlink so that the contents
of the file weren't exported.
Hope that helps!
--
"Oh, look: rocks!"
-- Doctor Who, "Destiny of the Daleks"
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2010-01-22 18:08 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-01-21 22:13 git-archive ignores export-ignore Todd A. Jacobs
2010-01-22 0:57 ` Junio C Hamano
2010-01-22 18:07 ` Todd A. Jacobs
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).