revlog: add a _datareadfp context manager for data access needs
The helper handles:
1) is there a file handle already open that we shall just reuse,
2) is the revlog inlined or not.
Using a context manager for all read access will help setting up file pointer
caching in later changesets.
mkcommit() {
echo "$1" > "$1"
hg add "$1"
hg ci -m "$1"
}
getid() {
hg log --hidden --template '{node}\n' --rev "$1"
}
cat >> $HGRCPATH <<EOF
[alias]
debugobsolete=debugobsolete -d '0 0'
EOF