git 的 gitignore 的用途

可以用 gitignore的方式来 无视清单内规定的东西。

创建一个新document, 然后命名为 .gitignore  (后面的 .txt要去掉)。

 

里面可以放你想要 git无视的东西:

1 *.txt
2 *.php
3 *.css
4 *.html

 

以上清单表示 git会无视 所有后辍是 .txt 、 .php 、 .css 、.html 的文件。

也可以无视某个文件夹,只需提供路径即可。

 

1 temp/*

 

以上清单表示无视同个目录下的 temp folder里面的所有东西。

posted @ 2019-03-15 00:59  Vui  阅读(1105)  评论(0编辑  收藏  举报