Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
可能重复: 如何让 git 忽略目录的所有内容?
如何指定永远不会添加的目录?
或其他目录总是被添加?
忽略所有目录的方法是使用.gitignore file模式: 在您的存储库中创建一个 .gitignore Ex:-
.gitignore file
if you have a directory name Test
所以只需在文件中添加这个文件 .gitignore夹
.gitignore
Test/
更多检查这个