Friday, August 10, 2012

.gitignore file not working

I have created a file to ignore some specific files and folders with git. I have created the following file:

abc
abc/*
xyx
xyx/*

When I try to add files with the below command:

git add *

I got the error 'no files added'.
Then I run:

git rm -r --cached .

This removes everything from the cache. Now I run the command:

git add .

Now it will add the files. So, I can commit the changes.
See the book OpenCart 1.4 Template Design Cookbook.
See the book Joomla Mobile Development Beginners Guide