error: sus cambios locales a los siguientes files se sobrescribirán con checkout: wp-config.php

Recibo el post "No hay nothing to commit, working directory clean " al ejecutar el command de estado de git

pero cuando se ejecuta el git checkout nombre-de-twig produce un error:

 error: Your local changes to the following files would be overwritten by checkout: wp-config.php 

Por favor, compruebe los commands de abajo git con el resultado:


 shahalom@microsolutionsbd ~/www/wp-projects/atoz-reviews $ git update-index --assume-unchanged -- wp-config.php shahalom@microsolutionsbd ~/www/wp-projects/atoz-reviews $ git status On branch master Changes not staged for commit: (use "git add <file>..." to update what will be committed) (use "git checkout -- <file>..." to discard changes in working directory) modified: .gitignore no changes added to commit (use "git add" and/or "git commit -a") shahalom@microsolutionsbd ~/www/wp-projects/atoz-reviews $ git diff .gitignore diff --git a/.gitignore b/.gitignore index d9d785e..d180ece 100644 --- a/.gitignore +++ b/.gitignore @@ -4,4 +4,3 @@ wp-content/plugins/wordpress-seo/ wp-content/plugins/wp-mail-smtp/ wp-content/plugins/jetpack/ wp-content/plugins/google-sitemap-generator/ -wp-config.php shahalom@microsolutionsbd ~/www/wp-projects/atoz-reviews $ git add .gitignore shahalom@microsolutionsbd ~/www/wp-projects/atoz-reviews $ git commit -F ../commitmsg.txt [master d265e1a] Remove wp-config.php file from gitignore because with .gitignore, only untracked files are ignonetworking. 1 file changed, 1 deletion(-) shahalom@microsolutionsbd ~/www/wp-projects/atoz-reviews $ git status On branch master nothing to commit, working directory clean shahalom@microsolutionsbd ~/www/wp-projects/atoz-reviews $ git push origin master Password for 'https://user_name@bitbucket.org': Counting objects: 3, done. Delta compression using up to 4 threads. Compressing objects: 100% (2/2), done. Writing objects: 100% (3/3), 488 bytes | 0 bytes/s, done. Total 3 (delta 2), reused 1 (delta 1) To https://user_name@bitbucket.org/user_name/atoz-reviews.git c7bebee..d265e1a master -> master shahalom@microsolutionsbd ~/www/wp-projects/atoz-reviews $ git status On branch master nothing to commit, working directory clean shahalom@microsolutionsbd ~/www/wp-projects/atoz-reviews $ git checkout develop error: Your local changes to the following files would be overwritten by checkout: wp-config.php Please, commit your changes or stash them before you can switch branches. Aborting shahalom@microsolutionsbd ~/www/wp-projects/atoz-reviews $ git stash save "Unknown changes with not file to commit" No local changes to save shahalom@microsolutionsbd ~/www/wp-projects/atoz-reviews $ git checkout develop error: Your local changes to the following files would be overwritten by checkout: wp-config.php Please, commit your changes or stash them before you can switch branches. Aborting 

Creo que está relacionado con git update-index --assume-unchanged -- wp-config.php command … pero ¿cuál es la solución?