git rebase for change commit log content(13)
reference :https://www.cnblogs.com/libra13179/p/11429302.html
执行 :git rebase -i HEAD~2
Set core.editor in your Git config: git config --global core.editor "vim"
Set the GIT_EDITOR environment variable: export GIT_EDITOR=vim
改成
edit bd33d0e +AHB-23 New Feature 新增DesignTacoControllerTest.class测试类 测试/design post返回的model status view属性
pick 1879ae8 +AHB-22 New Feature 新增DesignTacoControllerTest.class测试类 模拟/design post表单提交,并测试返回结果
然后保存退出:
root#:/tmp/panzidong/SpringInAction502DevelopingWebApplication# git commit --amend
[detached HEAD c4008c6] +AHB-22 New Feature 新增DesignTacoControllerTest.class测试类 测试/design post返回的model status view属性
Author: lianghong <642936744@qq.com>
Date: Fri Mar 27 09:43:41 2020 +0800
2 files changed, 64 insertions(+)
create mode 100644 src/test/java/tacos/DesignTacoControllerTest.java
root#:/tmp/panzidong/SpringInAction502DevelopingWebApplication# git status
interactive rebase in progress; onto e2832b4
Last command done (1 command done):
edit bd33d0e +AHB-23 New Feature 新增DesignTacoControllerTest.class测试类 测试/design post返回的model status view属性
Next command to do (1 remaining command):
pick 1879ae8 +AHB-22 New Feature 新增DesignTacoControllerTest.class测试类 模拟/design post表单提交,并测试返回结果
(use "git rebase --edit-todo" to view and edit)
You are currently editing a commit while rebasing branch 'master' on 'e2832b4'.
(use "git commit --amend" to amend the current commit)
(use "git rebase --continue" once you are satisfied with your changes)
nothing to commit, working tree clean
root#v:/tmp/panzidong/SpringInAction502DevelopingWebApplication# git rebase --continue
Successfully rebased and updated refs/heads/master.
#git push origin master --force