1.在github上下载gitignore项目,地址为https://www.github.com/github/gitignore
2.终端中cd进入到项目目录
3.在下载到的gitignore文件夹中找到对应的语言,然后终端中通过cp XXXX.gitignore .gitignore将gitignore拷贝到项目中
4.git add .命令将该文件添加到git管理
5.提交到git仓库 git commit -m “XXX”
6.提交到git服务器 git push
添加gitignore的方法
最新推荐文章于 2025-03-23 14:54:19 发布