haproxy/scripts
Willy Tarreau f97db23b6d SCRIPTS: git-show-backports: automatic ref and base detection with -m
When running with -m (check for missing backports) we often have to fill
lots of information that can be determined automatically the vast majority
of the time:
  - restart point (last cherry-picked ID from one of the last commits)
  - current branch (HEAD)
  - reference branch (the one that contains most of the last commits)

These elements are not that hard to determine, so let's make sure we
can fall back to them when running in missing mode.

The reference branch is guessed by looking at the upstream branch that
most frequently contains some of the last 10 commits. It can be inaccurate
if multiple branches exist with these commits, or when upstream changes
due to a non-LTS branch disappearing in the middle of the series, in which
case passing "-r" will help. But most of the time it works OK. It also gives
precedence to local branches over remote ones for such choices. A test in
2.4 at commit 793a4b520 correctly shows 2.6/master as the upstream despite
2.5 having been used for the early ones of the tag.

For the restart point, we assume that the most recent commit that was
backported serves as a reference (and not the most recently backported
commit). This means that the usual case where an old commit was found
to be missing will not fool the analysis. Commits are inspected from
2 commits before the last tag, and reordered from the parent's tree
to see which one is the last one.

With this, it's sufficient to issue "git-show-backports -q -m" to get
the list of backports from the upstream branch, restarting from the
last backported one.
2023-08-14 13:12:56 +02:00
..
announce-release SCRIPTS: announce-release: add a link to the data plane API 2022-11-28 07:31:54 +01:00
backport
build-ot.sh
build-ssl.sh BUILD: ssl: switch LibreSSL to Fastly CDN 2023-04-26 18:41:03 +02:00
build-vtest.sh
create-release
git-show-backports SCRIPTS: git-show-backports: automatic ref and base detection with -m 2023-08-14 13:12:56 +02:00
make-releases-json CLEANUP: assorted typo fixes in the code and comments 2022-10-30 17:17:56 +01:00
publish-release SCRIPTS: publish-release: update the umask to keep group write access 2023-05-24 22:49:12 +02:00
run-regtests.sh SCRIPTS: run-regtests: add a version check 2022-11-30 18:44:33 +01:00