我在师父上,我做到了 rebase -i <my_branch>
明白啦:
noop
# Rebase c947bec..7e259d3 onto c947bec
#
# Commands:
# p, pick = use commit
# r, reword = use commit, but edit the commit message
# e, edit = use commit, but stop for amending
# s, squash = use commit, but meld into previous commit
# f, fixup = like "squash", but discard this commit's log message
# x <cmd>, exec <cmd> = Run a shell command <cmd>, and stop if it fails
#
# If you remove a line here THAT COMMIT WILL BE LOST.
# However, if you remove everything, the rebase will be aborted.
#
我想选择一些提交,但并非全部,因为其中一些不受欢迎。另外,当您要保留某些文件或对分支始终总是“本地”更改时,如何工作?有喜欢的帮手.gitignore
吗?
HEAD~*
语法对我有用,但第一个没有。