contrib/merge-test-compat.sh
author Pierre-Yves David <pierre-yves.david@octobus.net>
Tue, 07 Nov 2017 12:10:22 +0100
branchstable
changeset 3172 aed2cac9edc3
parent 3133 13a4c35f7a0b
child 5080 6db9e2350948
permissions -rwxr-xr-x
wireproto: avoid exposing pushkey abort for server without evolution Client with evolution enabled will query the 'obsolete' pushley namespace if no other way to request obsmarkers have been found. They will do this unconditionally as long as no other obsolescence related capabilities have been advertised by the server. The call is "harmless" since the namespace will be empty if obsmarkers exchange is disabled. However, since we forbid the use of pushkey for obsmarkers this lead to unexpected crash report for up to date client talking to a server with the evolve extensions but exchange disabled. We fix the issue by serving the expected empty namespace in this case. We keep forbidding the query if obsmarker exchange is enabled since new client should have picked another more effective was to fetch the data first. We also add some tests for this logic.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
3133
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
     1
#!/bin/bash
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
     2
set -euox pipefail
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
     3
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
     4
unset GREP_OPTIONS
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
     5
NOTOPIC="--config experimental.topic-mode=ignore"
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
     6
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
     7
compatbranches=`hg branches --quiet | grep 'mercurial-' | grep -v ':' | sort -n --reverse`
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
     8
prev='stable'
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
     9
for branch in $compatbranches; do
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
    10
    hg up $branch
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
    11
    hg merge $prev
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
    12
    hg commit -m "test-compat: merge $prev into $branch"
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
    13
    prev=$branch
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
    14
done
13a4c35f7a0b util: add a small script to help with the merging of branches
Pierre-Yves David <pierre-yves.david@octobus.net>
parents:
diff changeset
    15