How about making the script check if cherry-picked commit is reverted by later commit.
It sounds to me like we're talking about a separate "backport sanity"
script, which would:
1. enumerate the commits in the backport PR
2. determine the master SHA1 each backport commit was cherry-picked from
3. check whether that SHA1 is reverted in master
I haven't tried automating operations like that, but I guess it wouldn't
be *too* hard. The script could also do stuff like check that the commit
message has the proper form.
There is also the question of how to mandate that backporters run this
script, given that apparently nobody (except me) uses the current
script. Here, I think the answer is to make a version of this "backport
sanity" script that would take a PR number. Then any reviewer could run
it on any open backport PR.
Thanks, Zheng - this is starting to sound like a really good thing to have!
Nathan