lakshmen
lakshmen

Reputation: 29064

gitignore file not working properly

I am trying to ignore the .pyc files in my folder and do not want to add them to my repository and i already created the gitignore file.

My gitignore file looks like this:

#python specific
*.pyc

##generic files to ignore
*~
*.lock
*.DS_Store
*.swp
*.out

Besides the .pyc file i want to ignore some other basic generic files. But when i type git add ., it still adds the .pyc files.

How do i solve this problem?Need some help...

Upvotes: 2

Views: 538

Answers (1)

Paul R
Paul R

Reputation: 212929

git expects the file to be named .gitignore, not gitignore (note the period at the start of the file name).

Upvotes: 3

Related Questions