Say I have a project with the following structure and I want to ignore everything in data folder but unignore all README.md file.
├── README.md
├── data
│ ├── README.md
│ ├── external
│ │ └── README.md
│ ├── interim
│ │ └── README.md
│ ├── processed
│ │ └── README.md
│ └── raw
│ └── README.md
├── hamlett
│ ├── README.md
│ ├── android
│ ├── models
│ │ ├── README.md
│ │ └── pigeon
│ │ └── README.md
│ ├── site
│ └── tools
└── models
└── README.md
I tried to put something like this in .gitignore
but seems not working.
data/*
!README.md
!**/README.md
!/**/README.md # none of the above 3 lines work...