Answer the question
In order to leave comments, you need to log in
Why is there an error in adding changed files to a previous commit?
I'm working on the master branch. At the current stage of development, a certain stage is indexed, a commit is made and launched into the repository.
Next, I change the files and want to add them to the previous commit
I do git add .
Next $ git commit --amend
No rules in editor, save and exit
Status says:
On branch master
Your branch and 'origin/master' have diverged,
and have 1 and 1 different commits each, respectively.
(use " git
pull" to merge the remote branch into yours)
nothing to
commit, working tree clean /test.git '
How to add changed files to previous commit and push?
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question