HOWTO populate the integration branch » History » Version 9
Loïc Dachary, 04/10/2015 09:01 AM
1 | 3 | Loïc Dachary | Before a backported commit can be merged into the release branch, it must be tested in an integration branch. It serves two purposes: |
---|---|---|---|
2 | |||
3 | * Detect trivial problems that would break the upgrade tests run on the release branch (they are run at the tip of the branch, not at the latest point release) |
||
4 | * Do not pollute the release branch with reverted commits (because it cannot be rebased) |
||
5 | 1 | Loïc Dachary | |
6 | 2 | Loïc Dachary | * create a giant-backport branch if it does not already exists |
7 | * reset it to ceph/giant |
||
8 | 1 | Loïc Dachary | * fetch all pull requests from github |
9 | * git merge all pull requests |
||
10 | * modify the pull requests individually to fix merge conflicts (i.e. they must merge cleanly, which may involving aggregating two pull requests into a single one designed to properly resolve the conflict) |
||
11 | * compile with ./autogen.sh ; ./configure ; make -j4 |
||
12 | * modify the pull requests individually to fix compilation errors |
||
13 | 9 | Loïc Dachary | |
14 | The following snippet can help |
||
15 | <pre> |
||
16 | git checkout -b firefly-backport ceph/firefly |
||
17 | git reset --hard ceph/firefly |
||
18 | PRS="3963 4185" |
||
19 | git fetch --force ceph $(for ref in $PRS ; do echo +refs/pull/$ref/head:refs/remotes/ceph/pull/$ref/head ; echo +refs/pull/$ref/merge:refs/remotes/ceph/pull/$ref/merge ; done) |
||
20 | for pr in $PRS ; do eval title=$(curl --silent https://api.github.com/repos/ceph/ceph/pulls/$pr | jq .title) ; echo $title ; git --no-pager log --oneline ceph/pull/$pr/merge^1..ceph/pull/$pr/merge^2 ; git merge -m "$(echo -e "Merge $pr: $title\n\nReviewed-by: Loic Dachary <ldachary@redhat.com>")" ceph/pull/$pr/head ; done |
||
21 | git push --force ceph firefly-backports |
||
22 | </pre> |