有很多這樣的問題,但是沒有一個能夠達到所需的解決方案。.gitignore - 將文件保存在GitHub上
如何忽略對本地文件的更改而未提交給github?例如:app/etc/local.xml
Github - 有正確的local.xml這個不應該被覆蓋! 我有一個本地.gitignore文件,其中包含應用程序/ etc/local.xml 但是,當我更改文件時,它仍然顯示爲已修改爲提交。
我曾嘗試:
git rm --cached app/etc/local.xml
但這從GitHub刪除文件,但它不那麼讓我繼續在本地編輯文件,它不會出現在提交。
如何將原始文件保存在github上?
這是洽所有文件和文件夾在我的.gitignore
'git update-index --assume-unchanged app/etc/local.xml'。 [條款和條件](https://www.git-scm.com/docs/git-update-index)適用。 – Boldewyn