From a9806e45bd328ae7972c3256392236a6360203fe Mon Sep 17 00:00:00 2001 From: "rick.chan" Date: Fri, 14 Aug 2020 15:08:46 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=AD=A3=20rebase=20=E6=96=B9?= =?UTF-8?q?=E6=B3=95.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: rick.chan --- Software/Applications/Git/Git_使用说明.md | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Software/Applications/Git/Git_使用说明.md b/Software/Applications/Git/Git_使用说明.md index dd62d7d..5e37986 100644 --- a/Software/Applications/Git/Git_使用说明.md +++ b/Software/Applications/Git/Git_使用说明.md @@ -324,7 +324,11 @@ git rebase [-i] [upstream] 通过增加 -i 参数可进入交互模式。使用 Rebase 还可以将多次提交进行合并,或设置起止点。 ```bash -git rebase [-i] [start commit id] [end commit id] +git rebase [-i] +# 合并最后 n 次提交 +git rebase [-i] HEAD~ +# 合并某个 commit id 以来的提交 +git rebase [-i] ``` 如果发生了冲突,可以在解决冲突并 add 后,通过: