clean bug on ignored subdirectories with no tracked files?
- From
Jay Soffian <jaysoffian@gmail.com>
- Date
- Nov 19, 2011, 05:38 UTC
- Message-ID
- <CAG+J_Dxw00e_cr7i3R9DAbTrqZvJHYk2yeUa=xGKh+Zqqmp-SA@mail.gmail.com>
git init test_repo && cd test_repo && mkdir -p foo/bar && echo baz > foo/bar/baz && echo /foo/bar > .gitignore && git add .gitignore && git clean -n -d
Initialized empty Git repository in .../test_repo/.git/ Would remove foo/
Seems surprising. The work-around is either using '/foo' in the top-level .gitignore or adding a tracked file to the 'foo' directory.
j.