All of lore.kernel.org
 help / color / mirror / Atom feed
* Git 2.7.0 gitignore behaviour regression
@ 2016-01-05 14:40 Mike McQuaid
  2016-01-05 15:06 ` Jeff King
  0 siblings, 1 reply; 13+ messages in thread
From: Mike McQuaid @ 2016-01-05 14:40 UTC (permalink / raw)
  To: git

Hi folks,

Firstly, thanks for all your hard work on Git. It makes my life much easier.

Homebrew has a series of convoluted .gitignore rules due to our special/weird use-case of wanting to ignore everything in a working directory except a select few files/directories. We experienced a bug with our .gitignore file for users using Git 2.7.0. This may well be a valid WONTFIX or intentional behaviour change but I wanted to flag it in case it wasn’t.

Here’s a minimal test case:

- Create an empty git repository in a directory with `git init`
- Create a directory named ‘a' containing a file named ‘b' with `mkdir a && touch a/b`
- Create a ‘gitignore’ file with the following contents:
```
*/
/a
!/a/*
```
- Run `git status --short`.

The output with Git 2.6.4 is:
```
?? .gitignore
```

The output with Git 2.7.0 is:
```
?? .gitignore
?? a/
```

Another minimal test case:

- Create an empty git repository in a directory with `git init`
- Create a directory named ‘a' containing a file named ‘b' with `mkdir a && touch a/b`
- Create a ‘gitignore’ file with the following contents:
```
*/
/a
!/a/
```
- Run `git status —short`.

The output with Git 2.6.4 is:
```
?? .gitignore
?? a/
```

The output with Git 2.7.0 is:
```
?? .gitignore
```

Let me know if you need any more information, thanks!

Mike McQuaid
http://mikemcquaid.com

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2016-01-08  9:02 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2016-01-05 14:40 Git 2.7.0 gitignore behaviour regression Mike McQuaid
2016-01-05 15:06 ` Jeff King
2016-01-06  9:42   ` Duy Nguyen
2016-01-06  9:50     ` Mike McQuaid
2016-01-06 10:03       ` Duy Nguyen
2016-01-06 18:58         ` Junio C Hamano
2016-01-07  2:04           ` Jeff King
2016-01-07  2:13             ` Duy Nguyen
2016-01-08  1:47             ` Carlos Martín Nieto
2016-01-07 23:44   ` brian m. carlson
2016-01-08  0:38     ` Duy Nguyen
2016-01-08  2:41       ` brian m. carlson
2016-01-08  9:02         ` Duy Nguyen

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.