GIT file to ignore all files inside a folder

Just create the folder you want to use but ignore all the files inside, for example, tmp and create the file .gitignore inside that folder.

./tmp/.gitignore

*
*/
!.gitignore