2

fossil-scm中,我有2个分支,并且樱桃选择了要在合并中应用的提交:

fossil merge --cherrypick chg01

如何从 branch1 发现哪些提交已合并到 branch2 ?实际上我需要知道哪些提交没有合并,以便在必要时合并它们。

在 git 中有这个命令可以做到这一点:

#view diffs between branches
git log --graph --left-right --cherry-pick --oneline branch1...branch2

在下面的示例中,我想知道rfc-02未应用于测试分支。

# ----------------------------------
# Create the repo and branches
# ----------------------------------

fossil new main.fossil
fossil ui main.fossil &
mkdir developer
cd developer
fossil clone ../main.fossil local.fossil
fossil open local.fossil
fossil branch new testing trunk
fossil branch new production testing
#
# ..[add some files]
#
fossil addremove
fossil ci -m "rfc-01 ticket [12345678]" --tag rfc-01

# ----------------------------------
# Let's merge that change
# ----------------------------------

cd ..
mkdir tests
cd tests
fossil clone ../main.fossil local.fossil
fossil open local.fossil testing
fossil merge --cherrypick rfc-01
#
# ..[add some files]
#
fossil addremove
fossil ci -m "rfc-01 tested [12345678]" --tag rev-01

# ----------------------------------
# Let's do more changes
# ----------------------------------

cd ../developer
fossil update
#
# ..[change/add some files]
#
fossil addremove
fossil ci -m "rfc-02 ticket [22345678]" --tag rfc-02
#
# ..[change/add some more files]
#
fossil addremove
fossil ci -m "rfc-03 ticket [32345678]" --tag rfc-03

# ----------------------------------
# Now merge one change
# ----------------------------------

cd ../tests
fossil update
fossil merge --cherrypick rfc-03
fossil addremove
fossil ci -m "rfc-03 tested [12345678]" --tag rev-03
4

0 回答 0