I want to ignore entire public_html/ directory except one file inside
I give .gitignore as below:
public_html/*
!public_html/config/config.php
However, when I run git status , I can not find config.php has been included.
Change .gitignore to
public_html/*
And force adding config.php into index.
git add -f public_html/config/config.php
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With