take only certain files with gitignore code example Example: gitignore all log files *.log !spec/*.log