tests/testlib/obsmarker-common.sh
author Manuel Jacob <me@manueljacob.de>
Thu, 05 Mar 2020 18:19:21 +0100
changeset 44467 fc70291f3d24
parent 42970 86f39a89b63e
permissions -rw-r--r--
tests: avoid implicit conversion of str to unicode On Python 2, str.encode('ascii') implicitly converts the string to unicode and then back to str. Since the converted value is a path, _bytespath can be used instead.

mkcommit() {
   name="$1"
   shift
   echo "$name" > "$name"
   hg add "$name"
   hg ci -m "$name" "$@"
}

getid() {
   hg log --hidden --template '{node}\n' --rev "$1"
}

cat >> $HGRCPATH <<EOF
[alias]
debugobsolete=debugobsolete -d '0 0'
EOF