# (unknown)

1 messages from 2014-08-26 to 2014-08-26. Participants: mail@glenstark.net.
Thread: https://gitlist.dev/t/37415

## mail@glenstark.net, 2014-08-26 11:16

Subject: (unknown)
Message-ID: <e1b2b0f6c0bdf4585f8e14ebacd68937.squirrel@webmail.glenstark.net>
URL: https://gitlist.dev/e/e1b2b0f6c0bdf4585f8e14ebacd68937.squirrel%40webmail.glenstark.net

```
Hi everyone.

Normally if I am tracking a file in a Directory which satisfies one of my
.gitignore rules, I can just add them via "git add foo", and I have no
issues.

For example, let me create a new repo.  I create a directory "lib"
containing file "foo.txt", and a Directory "lib2" with a file "bar.txt". 
I add and commit both files.

Now I create a .gitignore file containing the rule "lib*/".  I modify
lib/foo.txt and lib2/bar.txt.  I do "git status" and I'm informed that
foo.txt and bar.txt are modified.  So far so good.

The following commands work as expected:
 git add lib/foo.txt
 git add lib2/bar.txt

But if I instead do:
  git add lib/foo.txt lib2/bar.txt

I get the following response:
  The following paths are ignored by one of your .gitignore files:
  lib
  lib2

I have verified this behavior in git 1.9.3 and 2.1.0.  Is this desired
behavior or is it a bug?  If it is desired behavior, could someone please
describe the utility to me?

Many thanks for your excellent work

Glen Stark

```
