view tests/test-bookmarks-strip @ 9857:24bc6e414610

diff: change --inverse to --reverse This fixes an incompatibility with patch(1), which also uses --reverse for reversed diffs. The --inverse flag was added in 3f522d2fa633. That name was chosen over --reverse since it was thought that --reverse would make --rev ambiguous. It turns out that both flags can co-exist, with the cost that --rev can no longer be shortened to --r and --re. Since one can always use the short -r option, this is not a real problem.
author Martin Geisler <mg@lazybytes.net>
date Sat, 14 Nov 2009 14:21:53 +0100
parents 9737041646bc
children 12e5149cafca
line wrap: on
line source

#!/bin/sh

echo "[extensions]" >> $HGRCPATH
echo "bookmarks=" >> $HGRCPATH
echo "mq=" >> $HGRCPATH

hg init

echo qqq>qqq.txt

echo % add file
hg add

echo % commit first revision
hg ci -m 1 -u user -d "1 0"

echo % set bookmark
hg book test

echo www>>qqq.txt

echo % commit second revision
hg ci -m 2 -u usr -d "1 0"

echo % set bookmark
hg book test2

echo % update to -2
hg update -r -2

echo eee>>qqq.txt

echo % commit new head
hg ci -m 3 -u user -d "1 0"

echo % bookmarks updated?
hg book

echo % strip to revision 1
hg strip 1 2>&1 | sed 's/\(saving bundle to \).*/\1/'

echo % list bookmarks
hg book