I've looked at some examples on how to ignore everything except certain sub directories like so.
# Ignore Everything
foo/*
# Include sub directory
!foo/ccc/*
I have also tried:
# Ignore Everything
foo/*
# Include sub directory
!foo/ccc/
UPDATE
So the code above works, however trying to exclude a directory within another directory within another does not work. It only works on the parent directory and sub directory.
# Ignore Everything
foo/*
# Include sub directory
!foo/ccc/aaa/ddd/
After I include this in my gitingore, I run a git add --all
and I dont see any the files in git status
.
All help would be appreciated.