Mercurial > hg
view tests/test-filebranch @ 1592:347c44611348
gpg signing extension for hg
the principle is almost the same as how tags work:
.hgsigs stores signatures, localsigs stores local signatures
the format of the signatures is:
nodeid sigversion base64_detached_sig
sigversion 0 signs simply the nodeid (maybe we would like
to sign other things in the future).
you can associate fingerprints with roles in hgrc like:
[gpg]
fingerprint_of_a_key_without_spaces = release
fingerprint_of_a_key_without_spaces = contributor, testing
the key used for signing can be specified on the command line or
via hgrc (key =)
thanks to Eric Hopper for testing and bugfixing
author | Benoit Boissinot <benoit.boissinot@ens-lyon.org> |
---|---|
date | Fri, 16 Dec 2005 11:12:08 -0600 |
parents | 6f274afc05c7 |
children | 7544700fd931 |
line wrap: on
line source
#!/bin/sh # This test makes sure that we don't mark a file as merged with its ancestor # when we do a merge. cat <<'EOF' > merge #!/bin/sh echo merging for `basename $1` EOF chmod +x merge echo creating base hg init a cd a echo 1 > foo echo 1 > bar echo 1 > baz echo 1 > quux hg add foo bar baz quux hg commit -m "base" -d "0 0" cd .. hg clone a b echo creating branch a cd a echo 2a > foo echo 2a > bar hg commit -m "branch a" -d "0 0" echo creating branch b cd .. cd b echo 2b > foo echo 2b > baz hg commit -m "branch b" -d "0 0" echo "we shouldn't have anything but n state here" hg debugstate | cut -b 1-16,35- echo merging hg pull ../a env HGMERGE=../merge hg update -vm echo 2m > foo echo 2b > baz echo new > quux echo "we shouldn't have anything but foo in merge state here" hg debugstate | cut -b 1-16,35- | grep "^m" hg ci -m "merge" -d "0 0" echo "main: we should have a merge here" hg debugindex .hg/00changelog.i echo "log should show foo and quux changed" hg log -v -r tip echo "foo: we should have a merge here" hg debugindex .hg/data/foo.i echo "bar: we shouldn't have a merge here" hg debugindex .hg/data/bar.i echo "baz: we shouldn't have a merge here" hg debugindex .hg/data/baz.i echo "quux: we shouldn't have a merge here" hg debugindex .hg/data/quux.i echo "manifest entries should match tips of all files" hg manifest echo "everything should be clean now" hg status hg verify