{"thread":{"id":"17198","subject":"How to exclude some files when using git-archive?","startedAt":"2009-01-16T02:40:11Z","lastAt":"2009-01-16T05:26:46Z","messageCount":3,"participants":["Ping Yin","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"100690","messageId":"46dff0320901151840l18257501x62a3fa1fe9701dc@mail.gmail.com","threadId":"17198","inReplyTo":null,"subject":"How to exclude some files when using git-archive?","fromName":"Ping Yin","fromEmail":"pkufranky@gmail.com","sentAt":"2009-01-16T02:40:11Z","receivedAt":"2009-01-16T02:40:11Z","isPatch":false,"sender":{"key":"pkufranky@gmail.com","avatar":"https://avatars.githubusercontent.com/u/5346?v=4"},"body":"I want to exclude .gitignore from the archive, but hasn't find a easy way\n\nPing Yin\n"},{"id":"100693","messageId":"7v4p00otpb.fsf@gitster.siamese.dyndns.org","threadId":"17198","inReplyTo":"46dff0320901151840l18257501x62a3fa1fe9701dc@mail.gmail.com","subject":"Re: How to exclude some files when using git-archive?","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2009-01-16T02:44:48Z","receivedAt":"2009-01-16T02:44:48Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Ping Yin <pkufranky@gmail.com> writes:\n\n> I want to exclude .gitignore from the archive, but hasn't find a easy way\n>\n> Ping Yin\n\n\"man gitattributes\", then look for export-ignore?\n"},{"id":"100701","messageId":"46dff0320901152126u2bb9ff55qce9a22c69276bc6a@mail.gmail.com","threadId":"17198","inReplyTo":"7v4p00otpb.fsf@gitster.siamese.dyndns.org","subject":"Re: How to exclude some files when using git-archive?","fromName":"Ping Yin","fromEmail":"pkufranky@gmail.com","sentAt":"2009-01-16T05:26:46Z","receivedAt":"2009-01-16T05:26:46Z","isPatch":false,"sender":{"key":"pkufranky@gmail.com","avatar":"https://avatars.githubusercontent.com/u/5346?v=4"},"body":"On Fri, Jan 16, 2009 at 10:44 AM, Junio C Hamano <gitster@pobox.com> wrote:\n> Ping Yin <pkufranky@gmail.com> writes:\n>\n>> I want to exclude .gitignore from the archive, but hasn't find a easy way\n>>\n>> Ping Yin\n>\n> \"man gitattributes\", then look for export-ignore?\n>\n>\n\nThanks. That's exactly what i want.\n\nOne question: It seems the .gitattributes doesn't take effect when\nusing following command\n\nGIT_DIR=A/.git git archive HEAD > A.tar\n\nwhere the files with attribute export-ignore are still exported.\n\nInstead, i have to run\n\ncd A && git archive HEAD > A.tar\n\nPing Yin\n"}]}