Monday, July 22, 2019

Changes not staged for commit:

When you get this command line error in Git Bash it will be followed with something like so in red listing the files not included in your attempt to commit:

modified: ../../../package.json

 
 

I do not yet know what is really going on with this, but the way to fix it is to try to add files again. However, do not just do this the next time:

git add .

 
 

Instead add the specific file as denoted in the red text like so:

git add ../../../package.json

 
 

Then you will be able to commit.

 
 

Addendum 1/24/2020: The problem stems from opening the shell where you are running GIT commands in a folder that does not include the change you need to loop in, a nested folder.

No comments:

Post a Comment