git避免 上传不需要的文件到代码库
 
1、创建.gitignore 文件,添加需要规避的文件或者文件夹
vim .gitignore
git命名 忽略不需要上传到代码库的文件或文件夹
2、使 .gitigore 文件生效
git config core.excludesfile .gitignore
git命名 忽略不需要上传到代码库的文件或文件夹
3、之后就可以
git add . 
git commit -m ''
git push 
 
【注意:】清除已add 的文件:
git rm -r --cached .
 
 
 

相关文章:

  • 2022-02-07
  • 2022-01-21
  • 2021-09-23
  • 2021-10-30
  • 2022-01-07
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2021-05-28
  • 2022-01-07
  • 2022-01-07
  • 2021-07-29
  • 2021-07-03
相关资源
相似解决方案