Patchwork commands: document clone bundles hooks and rollback behavior

login
register
mail settings
Submitter Gregory Szorc
Date Jan. 15, 2016, 5:22 a.m.
Message ID <837cffa71f7927855559.1452835327@ubuntu-vm-main>
Download mbox | patch
Permalink /patch/12779/
State Accepted
Headers show

Comments

Gregory Szorc - Jan. 15, 2016, 5:22 a.m.
# HG changeset patch
# User Gregory Szorc <gregory.szorc@gmail.com>
# Date 1452835319 28800
#      Thu Jan 14 21:21:59 2016 -0800
# Node ID 837cffa71f7927855559b85209d2fa9704a9b20e
# Parent  63116d47cc3fd179c90b117397cc26341a381edb
commands: document clone bundles hooks and rollback behavior

The added content is inside a verbose container.

I figure it makes sense to explicitly document behavior, including
with the caveat it may change later. People can't say they weren't
warned!
Matt Mackall - Jan. 18, 2016, 1:25 a.m.
On Thu, 2016-01-14 at 21:22 -0800, Gregory Szorc wrote:
> # HG changeset patch
> # User Gregory Szorc <gregory.szorc@gmail.com>
> # Date 1452835319 28800
> #      Thu Jan 14 21:21:59 2016 -0800
> # Node ID 837cffa71f7927855559b85209d2fa9704a9b20e
> # Parent  63116d47cc3fd179c90b117397cc26341a381edb
> commands: document clone bundles hooks and rollback behavior

Queued for default, thanks. Reminder: doc fixes are also welcome after the
freeze.

-- 
Mathematics is the supreme nostalgia of our time.

Patch

diff --git a/mercurial/commands.py b/mercurial/commands.py
--- a/mercurial/commands.py
+++ b/mercurial/commands.py
@@ -1500,16 +1500,24 @@  def clone(ui, source, dest=None, **opts)
          latest head of that branch)
       d) the changeset specified with -r
       e) the tipmost head specified with -b
       f) the tipmost head specified with the url#branch source syntax
       g) the revision marked with the '@' bookmark, if present
       h) the tipmost head of the default branch
       i) tip
 
+      When cloning from servers that support it, Mercurial may fetch
+      pre-generated data from a server-advertised URL. When this is done,
+      hooks operating on incoming changesets and changegroups may fire twice,
+      once for the bundle fetched from the URL and another for any additional
+      data not fetched from this URL. In addition, if an error occurs, the
+      repository may be rolled back to a partial clone. This behavior may
+      change in future releases. See :hg:`help -e clonebundles` for more.
+
       Examples:
 
       - clone a remote repository to a new directory named hg/::
 
           hg clone http://selenic.com/hg
 
       - create a lightweight local clone::