git ignore all folders code example Example 1: git ignore all files and folders in folder * */ !.gitignore Example 2: git ignore folder command $ touch .gitignore