1,rebase命令介紹
rebase 主要作用如其名:重新設置基點到指定位置。此外還可以結合squash操作進行提交記錄壓縮,結合drop操作進行提交記錄刪除,選取連續到提交記錄轉移到指定分支。
2,rebase官方參數
NNAAMMEE
git-rebase - Reapply commits on top of another base tip
SYNOPSIS
git rebase [-i | --interactive] [<options>] [--exec <cmd>] [--onto <newbase> | --keep-base] [<upstream> [<branch>]]
git rebase [-i | --interactive] [<options>] [--exec <cmd>] [--onto <newbase>] --root [<branch>]
git rebase (--continue | --skip | --abort | --quit | --edit-todo | --show-current-patch)
3,官方中文文檔:
https://git-scm.com/book/zh/v2/Git-%E5%88%86%E6%94%AF-%E5%8F%98%E5%9F%BA