GitExtensions ignoring .gitignore

Kirinkunhime picture Kirinkunhime · Sep 5, 2014 · Viewed 10.8k times · Source

I am trying to use git as my VCS for a small project. (Using 2 PCs, both windows)

As I don't like bash I am using gitExtensions, but somehow my .gitignore seems to get ignored by it. This is what my .gitignore looks like:

nbproject/private/
build/
nbbuild/
dist/
nbdist/
nbactions.xml
nb-configuration.xml
build.xml

Now, my folder-structure looks somewhat like this:

E:.
├───lib
│   └───<libary stuff>
└───trunk
    ├───build
    │   ├───empty
    │   ├───generated-sources
    │   └───web
    ├───dist
    ├───nbproject
    │   └───private
    ├───src
    │   ├───conf
    │   └───java
    └───web

Unfortunately it still includes the whole build folder, and every time I build it i get various new edited files in e.g. the build/generated-sources/ or the dist/, or build/web/

I'm quite new to using .gitignore, so please bear with my low knowledge about it.

Thanks and I appreciate the help.

Answer

jub0bs picture jub0bs · Sep 5, 2014

The files that you're trying to ignore may already be under version control. If that's the case, you need to remove them from version control, then make a commit. After that, what's listed in .gitignore should be properly ignored.

To figure out how to remove files in Git Extensions (v2.48), have a look at the online documentation. Besides, KindDragon mentions, in his comment, a feature recently added, called "Show ignored files", which you might find useful.