I have few folders in git repo. Every folder contains an "arm" folder which is included to .gitignore
file. But I have a few Makefiles in "arm" folder and in subfolders of arm folder. When I make changes in Makefiles which is under source control git status
show me the changes. But if I create new subfolder in "arm" folder and add Makefile git status
output is empty. How can I change .gitignore
file to see untracked Makefiles in git status
output?
Asked
Active
Viewed 2,485 times
3

Max Leske
- 5,007
- 6
- 42
- 54

Alexey Shaykhiev
- 47
- 2
-
[this](http://stackoverflow.com/questions/5533050/gitignore-exclude-folder-but-include-specific-subfolder) might help you! Also post your .gitignore. – Boj Oct 30 '13 at 07:33
2 Answers
0
It is better to add Makefile to your Git using the command line:
git add -f Makefile

Sohrab
- 1,348
- 4
- 13
- 33
-1
You can add the Makefile overriding the .gitignore
configuration, with git add -f arm/Makefile
, making git still ignore what is in the folder except for the Makefile that is tracked by it anyway now.
Or you can add the exception for Makefiles on the .gitignore
, like:
arm/*
!arm/Makefile

talles
- 14,356
- 8
- 45
- 58