.gitignore文件的使用

时间:2021-02-23 14:18:35   收藏:0   阅读:0

我们一般会在项目根目录加上.gitignore文件,但是有些初始的项目并没有这个文件,于是需要我们主动增加这个文件。

文件的参考内容如下:

.DS_Store
node_modules/
/dist/
npm-debug.log*
yarn-debug.log*
yarn-error.log*
/test/unit/coverage/
/test/e2e/reports/
selenium-debug.log

# Editor directories and files
.idea
.vscode
*.suo
*.ntvs*
*.njsproj
*.sln

该文件屏蔽了node_modules(依赖)、dist(编译生成的代码)、.vscode(vscode生成的文件)、.idea(idea生成的文件)等文件的上传。

 

评论(0
© 2014 mamicode.com 版权所有 京ICP备13008772号-2  联系我们:gaon5@hotmail.com
迷上了代码!