Mercurial > hg
view tests/test-hooklib-enforce_draft_commits.t @ 46520:c82d6363bc9e
packaging: add Provides: python3-mercurial and Homepage to debian package
There are other packages that depend on python3-mercurial, like debian's
mercurial-git, so we should mark ourselves as providing it.
I compared the control file we generate to the one that the debian maintainers
generate, and noticed several differences:
- the Homepage bit. I included this, because why not
- a more robust Suggests list that includes a graphical merge tool
- a more robust Breaks list
- debian's Recommends openssh-client, we only Recommends ca-certificates
- a split into `mercurial` and `mercurial-common` (and possibly others?)
- a slightly different description
Differential Revision: https://phab.mercurial-scm.org/D9983
author | Kyle Lippincott <spectral@google.com> |
---|---|
date | Thu, 11 Feb 2021 11:22:53 -0800 |
parents | 4cabeea6d214 |
children |
line wrap: on
line source
$ cat <<EOF >> $HGRCPATH > [extensions] > hooklib = > > [phases] > publish = False > EOF $ hg init a $ hg --cwd a debugbuilddag . $ hg --cwd a phase --public 0 $ hg init b $ cat <<EOF >> b/.hg/hgrc > [hooks] > pretxnclose-phase.enforce_draft_commits = \ > python:hgext.hooklib.enforce_draft_commits.hook > EOF $ hg --cwd b pull ../a pulling from ../a requesting all changes adding changesets adding manifests adding file changes error: pretxnclose-phase.enforce_draft_commits hook failed: New changeset 1ea73414a91b in phase 'public' rejected transaction abort! rollback completed abort: New changeset 1ea73414a91b in phase 'public' rejected [255] $ hg --cwd a phase --force --draft 0 $ hg --cwd b pull ../a pulling from ../a requesting all changes adding changesets adding manifests adding file changes added 1 changesets with 0 changes to 0 files new changesets 1ea73414a91b (1 drafts) (run 'hg update' to get a working copy) $ hg --cwd a phase --public 0 $ hg --cwd b pull ../a pulling from ../a searching for changes no changes found error: pretxnclose-phase.enforce_draft_commits hook failed: Phase change from 'draft' to 'public' for 1ea73414a91b rejected abort: Phase change from 'draft' to 'public' for 1ea73414a91b rejected [255]