From: "Florian Köberle" <florian@fkoeberle.de>
To: Michael J Gruber <git@drmicha.warpmail.net>
Cc: git@vger.kernel.org
Subject: Re: gitignore bug: including files in an excluded directoy does not work.
Date: Fri, 29 May 2009 23:25:41 +0200 [thread overview]
Message-ID: <4A2052D5.80604@fkoeberle.de> (raw)
In-Reply-To: <4A1DA8A7.9030606@drmicha.warpmail.net>
Michael J Gruber wrote:
> Florian Köberle venit, vidit, dixit 23.05.2009 11:18:
>
>> steps to reproduce:
>>
>> git init
>> echo /src/config > .gitignore
>> echo \!/src/config/readme.txt >> .gitignore
>> mkdir -p src/config
>> touch src/config/readme.txt
>> git add src
>>
>> expected results:
>> git should add the readme.txt file
>>
>> actual result:
>> git doesn't add the readme.txt file
>>
>>
>> additional comments:
>>
>> pre to the commit d6b8fc303b it was possible to archive the wished effect
>> with this .gitignore file:
>> ------------------
>> /src/config/
>> !/src/config/readme.txt
>> ------------------
>> The pre d6b8fc303b git fails to detect that it can exclude src/config.
>> Thus it checks the directory content and finds out that the readme.txt
>> matches both - the exclude and the include pattern.
>>
>
> The change in behaviour was intentional. You get the desired effect using:
>
> /src/config/*
> !/src/config/readme.txt
>
> Cheers,
> Michael
> --
> To unsubscribe from this list: send the line "unsubscribe git" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
>
>
>
Hello Michael,
thanks for the explanation.
Best regards,
Florian
prev parent reply other threads:[~2009-05-29 21:48 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-05-23 9:18 gitignore bug: including files in an excluded directoy does not work Florian Köberle
2009-05-27 20:55 ` Michael J Gruber
2009-05-29 21:25 ` Florian Köberle [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4A2052D5.80604@fkoeberle.de \
--to=florian@fkoeberle.de \
--cc=git@drmicha.warpmail.net \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).