This is the content of my "root" .gitignore
# exclude everything ...
*
# ...except
!/.gitignore
!*/
!/modules/wp-azth/**
the problem is that, under modules folder, i've a lot of third-party modules with a .gitignore file inside.
Using rules above, all third-party modules folders are ignored but their .gitignore files are not ( and i don't need it of course )
is there a way to ignore .gitignore files inside ignored subfolders? maybe .git/config can be used for this?
( i think it's a bad behaviour of git that considers them even if they are ignored )
UPDATE: It seems a lack of git, it allows ignored folder to "arbitrary" un-ignore itself having !.gitignore rule inside a gitignore file placed ( by anyone ) inside an ignored subdirectory. Ignored folders normally could contains files that are dynamic , temporary or 3rd party ( cache, temp, plugins etc ) ... so git allows to create unwanted behaviours just using a simple !.gitignore as rule inside subdirectory.