简体   繁体   中英

How to remove certain file directories from .gitignore about Git

I performed the following operations as an example

echo '.temp' >> .gitignore
echo '.cache' >> .gitignore

Now I want to remove it from .gitignore

What should I do?

I suppose you want to do this using script.

Try something like :

sed -e s/deletethis//g -i .gitignore

(this solution has not been tested)

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM