Patchwork [4,of,4] commands: split notes into note containers

login
register
mail settings
Submitter timeless@mozdev.org
Date Dec. 22, 2015, 6:15 a.m.
Message ID <250c89298ef7aca9c4cb.1450764955@waste.org>
Download mbox | patch
Permalink /patch/12234/
State Accepted
Headers show

Comments

timeless@mozdev.org - Dec. 22, 2015, 6:15 a.m.
# HG changeset patch
# User timeless <timeless@mozdev.org>
# Date 1450764180 0
#      Tue Dec 22 06:03:00 2015 +0000
# Node ID 250c89298ef7aca9c4cb0f8fcb12fcd6345092aa
# Parent  f825d568b2a3d23af05ea8745ae75548710f613d
commands: split notes into note containers
Matt Mackall - Dec. 22, 2015, 10:57 p.m.
On Tue, 2015-12-22 at 00:15 -0600, timeless wrote:
> # HG changeset patch
> # User timeless <timeless@mozdev.org>
> # Date 1450764180 0
> #      Tue Dec 22 06:03:00 2015 +0000
> # Node ID 250c89298ef7aca9c4cb0f8fcb12fcd6345092aa
> # Parent  f825d568b2a3d23af05ea8745ae75548710f613d
> commands: split notes into note containers
> 
> diff --git a/mercurial/commands.py b/mercurial/commands.py
> --- a/mercurial/commands.py
> +++ b/mercurial/commands.py
> @@ -1458,9 +1458,12 @@
>      identifiers with -r/--rev or branches with -b/--branch. The
>      resulting clone will contain only the specified changesets and
>      their ancestors. These options (or 'clone src#rev dest') imply
> -    --pull, even for local source repositories. Note that specifying a
> -    tag will include the tagged changeset but not the changeset
> -    containing the tag.
> +    --pull, even for local source repositories.
> +
> +    .. note::
> +
> +       Specifying a tag will include the tagged changeset but not the
> +       changeset containing the tag.

This one should point people to --updaterev.

-- 
Mathematics is the supreme nostalgia of our time.
Matt Mackall - Dec. 22, 2015, 10:57 p.m.
On Tue, 2015-12-22 at 00:15 -0600, timeless wrote:
> # HG changeset patch
> # User timeless <timeless@mozdev.org>
> # Date 1450764180 0
> #      Tue Dec 22 06:03:00 2015 +0000
> # Node ID 250c89298ef7aca9c4cb0f8fcb12fcd6345092aa
> # Parent  f825d568b2a3d23af05ea8745ae75548710f613d
> commands: split notes into note containers

These are queued for default, thanks.

-- 
Mathematics is the supreme nostalgia of our time.
timeless - Dec. 29, 2015, 12:18 a.m.
Matt Mackall wrote:
> This one should point people to --updaterev.

I'm not sure what you want here.
Matt Mackall - Jan. 2, 2016, 12:55 a.m.
On Mon, 2015-12-28 at 19:18 -0500, timeless wrote:
> Matt Mackall wrote:
> > This one should point people to --updaterev.
> 
> I'm not sure what you want here.

People mostly abuse "hg clone -r foo" as a shorthand for pull and update to foo
and are sad when foo is a tag. They should only be using -r (often WAY slower
than clone) only when they really need a precise subset of changes.

The right thing is hg clone -u foo.
timeless - Jan. 5, 2016, 7:36 p.m.
Ok, the laziest thing I can do is reorder the text.
currently we do:
to pull subset
--note
explain @
to checkout foo

I think moving @+checkout foo before pull subset would probably
address the average case.

I think it's probably also the right thing to do, since
proportionally, people are much more likely to be interested in @/foo
than subseting.

Sound good enough?

On Fri, Jan 1, 2016 at 7:55 PM, Matt Mackall <mpm@selenic.com> wrote:
> On Mon, 2015-12-28 at 19:18 -0500, timeless wrote:
>> Matt Mackall wrote:
>> > This one should point people to --updaterev.
>>
>> I'm not sure what you want here.
>
> People mostly abuse "hg clone -r foo" as a shorthand for pull and update to foo
> and are sad when foo is a tag. They should only be using -r (often WAY slower
> than clone) only when they really need a precise subset of changes.
>
> The right thing is hg clone -u foo.
>
> --
> 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
@@ -1458,9 +1458,12 @@ 
     identifiers with -r/--rev or branches with -b/--branch. The
     resulting clone will contain only the specified changesets and
     their ancestors. These options (or 'clone src#rev dest') imply
-    --pull, even for local source repositories. Note that specifying a
-    tag will include the tagged changeset but not the changeset
-    containing the tag.
+    --pull, even for local source repositories.
+
+    .. note::
+
+       Specifying a tag will include the tagged changeset but not the
+       changeset containing the tag.
 
     If the source repository has a bookmark called '@' set, that
     revision will be checked out in the new repository by default.
@@ -5357,10 +5360,13 @@ 
     When ``default-push`` is set, it will be used for push and
     ``default`` will be used for pull; otherwise ``default`` is used
     as the fallback for both.  When cloning a repository, the clone
-    source is written as ``default`` in ``.hg/hgrc``.  Note that
-    ``default`` and ``default-push`` apply to all inbound (e.g.
-    :hg:`incoming`) and outbound (e.g. :hg:`outgoing`, :hg:`email` and
-    :hg:`bundle`) operations.
+    source is written as ``default`` in ``.hg/hgrc``.
+
+    .. note::
+
+       ``default`` and ``default-push`` apply to all inbound (e.g.
+       :hg:`incoming`) and outbound (e.g. :hg:`outgoing`, :hg:`email`
+       and :hg:`bundle`) operations.
 
     See :hg:`help urls` for more information.
 
@@ -5833,9 +5839,11 @@ 
     - :hg:`resolve -l`: list files which had or still have conflicts.
       In the printed list, ``U`` = unresolved and ``R`` = resolved.
 
-    Note that Mercurial will not let you commit files with unresolved
-    merge conflicts. You must use :hg:`resolve -m ...` before you can
-    commit after a conflicting merge.
+    .. note::
+
+       Mercurial will not let you commit files with unresolved merge
+       conflicts. You must use :hg:`resolve -m ...` before you can
+       commit after a conflicting merge.
 
     Returns 0 on success, 1 if any files fail a resolve attempt.
     """