tests/testlib/map-hg-rev.sh
author Anton Shestakov <av6@dwimlabs.net>
Thu, 30 Jan 2020 14:32:09 +0700
branchmercurial-4.7
changeset 5103 e9e5751f8de4
parent 4966 4f3c87584a4a
permissions -rwxr-xr-x
test-compat: merge mercurial-4.8 into mercurial-4.7

#!/bin/sh
set -eu

case $1 in
    default)
        echo default
        ;;
    mercurial-*)
        exp=$(echo "$1" | cut -d- -f2 | sed 's#\.#\\.#g')
        echo 'max(tag("re:^'"$exp"'"))'
        ;;
    *)
        echo stable
        ;;
esac