How to Git Ignore These Files

2019-02-22 06:52发布

问题:

I'm having a little trouble figuring out how to ignore all of these files that are created w/ Solr/Sunspot.

Basically I want to ignore everything inside of solr/data which includes a lot of folders, subfolders, and files.

回答1:

Just add

/solr/data

to your .gitignore.

Assumed directory layout:

.git
.gitignore
solr/data/
other/
folders/
README.txt
...


回答2:

You should be able to do /solr/data or put a .gitignore file inside solr/data and just put *.

Note that you can't ignore things that have already been committed.



标签: git gitignore