tests/test-tutorial.t
author Pierre-Yves David <pierre-yves.david@fb.com>
Thu, 27 Feb 2014 19:58:08 -0800
changeset 817 c2bf0eb727f1
parent 803 b96d51a357bd
child 823 9aa20585e158
permissions -rw-r--r--
exchange: only push the set of marker relevant to want we push We now compute all markers relevant to pushed set. And just send just those one. So you are no longer pushing markers that point to changeset your are not pushing. See the in line comment for details about what "relevant" is. Multiple nice output have been added in the process.
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
     1
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
     2
Initial setup
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
     3
-------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
     4
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
     5
This Mercurial configuration example is used for testing.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
     6
.. Various setup
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
     7
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
     8
  $ cat >> $HGRCPATH << EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
     9
  > [ui]
766
32936a9f4389 doc: some documentation on the configuration part of the tutorial
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 750
diff changeset
    10
  > # This is change the default output of log for clear tutorial
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    11
  > logtemplate ="{node|short} ({phase}): {desc}\n"
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    12
  > [diff]
766
32936a9f4389 doc: some documentation on the configuration part of the tutorial
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 750
diff changeset
    13
  > # use "git" diff format, clearer and smarter format
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    14
  > git = 1
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    15
  > [alias]
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    16
  > # "-d '0 0'" means that the new commit will be at January 1st 1970.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    17
  > # This is used for stable hash during test
766
32936a9f4389 doc: some documentation on the configuration part of the tutorial
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 750
diff changeset
    18
  > # (this tutorial is automatically tested.)
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    19
  > amend = amend -d '0 0'
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    20
  > EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    21
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    22
  $ hg init local
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    23
  $ cat >> local/.hg/hgrc << EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    24
  > [paths]
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    25
  > remote = ../remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    26
  > other = ../other
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    27
  > [ui]
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    28
  > user = Babar the King
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    29
  > EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    30
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    31
  $ hg init remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    32
  $ cat >> remote/.hg/hgrc << EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    33
  > [paths]
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    34
  > local = ../local
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    35
  > [ui]
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    36
  > user = Celestine the Queen
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    37
  > EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    38
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    39
  $ hg init other
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    40
  $ cat >> other/.hg/hgrc << EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    41
  > [ui]
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    42
  > user = Princess Flore
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    43
  > EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    44
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    45
654
c56109c9aebf tutorial: fix grammar, spelling, punctuation
Greg Ward <greg@gerg.ca>
parents: 652
diff changeset
    46
This tutorial uses the following configuration for Mercurial:
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    47
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    48
A compact log template with phase data:
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    49
766
32936a9f4389 doc: some documentation on the configuration part of the tutorial
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 750
diff changeset
    50
  $ hg showconfig ui | grep log
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    51
  ui.logtemplate="{node|short} ({phase}): {desc}\n"
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    52
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    53
Improved git format diff:
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    54
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    55
  $ hg showconfig diff
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    56
  diff.git=1
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    57
508
d1c658a6d0bc test-tutorial: stop using enable.sh, removed by 53d7e3413337
Patrick Mezard <patrick@mezard.eu>
parents: 492
diff changeset
    58
And of course, we enable the experimental extensions for mutable history:
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    59
508
d1c658a6d0bc test-tutorial: stop using enable.sh, removed by 53d7e3413337
Patrick Mezard <patrick@mezard.eu>
parents: 492
diff changeset
    60
  $ cat >> $HGRCPATH <<EOF
d1c658a6d0bc test-tutorial: stop using enable.sh, removed by 53d7e3413337
Patrick Mezard <patrick@mezard.eu>
parents: 492
diff changeset
    61
  > [extensions]
766
32936a9f4389 doc: some documentation on the configuration part of the tutorial
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 750
diff changeset
    62
  > evolve = $TESTDIR/../hgext/evolve.py
32936a9f4389 doc: some documentation on the configuration part of the tutorial
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 750
diff changeset
    63
  > # enabling rebase is also needed for now
508
d1c658a6d0bc test-tutorial: stop using enable.sh, removed by 53d7e3413337
Patrick Mezard <patrick@mezard.eu>
parents: 492
diff changeset
    64
  > rebase =
d1c658a6d0bc test-tutorial: stop using enable.sh, removed by 53d7e3413337
Patrick Mezard <patrick@mezard.eu>
parents: 492
diff changeset
    65
  > EOF
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    66
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    67
-----------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    68
Single Developer Usage
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    69
-----------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    70
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    71
This tutorial shows how to use evolution to rewrite history locally.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    72
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    73
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    74
Fixing mistake with `hg amend`
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    75
--------------------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    76
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    77
We are versionning a shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    78
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    79
  $ cd local
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    80
  $ cat  >> shopping << EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    81
  > Spam
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    82
  > Whizzo butter
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    83
  > Albatross
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    84
  > Rat (rather a lot)
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    85
  > Jugged fish
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    86
  > Blancmange
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    87
  > Salmon mousse
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    88
  > EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    89
  $ hg commit -A -m "Monthy Python Shopping list"
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    90
  adding shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    91
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    92
Its first version is shared with the outside.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    93
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    94
  $ hg push remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    95
  pushing to $TESTTMP/remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    96
  searching for changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    97
  adding changesets
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    98
  adding manifests
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
    99
  adding file changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   100
  added 1 changesets with 1 changes to 1 files
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   101
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   102
Later I add additional item to my list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   103
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   104
  $ cat >> shopping << EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   105
  > Egg
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   106
  > Suggar
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   107
  > Vinegar
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   108
  > Oil
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   109
  > EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   110
  $ hg commit -m "adding condiment"
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   111
  $ cat >> shopping << EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   112
  > Bananos
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   113
  > Pear
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   114
  > Apple
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   115
  > EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   116
  $ hg commit -m "adding fruit"
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   117
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   118
This history is very linear
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   119
634
e763f7e94211 tutorial: glog is into core now
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 590
diff changeset
   120
  $ hg log -G
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   121
  @  d85de4546133 (draft): adding fruit
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   122
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   123
  o  4d5dc8187023 (draft): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   124
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   125
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   126
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   127
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   128
But a typo was made in Babanas!
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   129
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   130
  $ hg export tip
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   131
  # HG changeset patch
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   132
  # User test
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   133
  # Date 0 0
726
06cd220141ba Adapt to human readable date in patch
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 696
diff changeset
   134
  #      Thu Jan 01 00:00:00 1970 +0000
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   135
  # Node ID d85de4546133030c82d257bbcdd9b1b416d0c31c
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   136
  # Parent  4d5dc81870237d492284826e21840b2ca00e26d1
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   137
  adding fruit
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   138
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   139
  diff --git a/shopping b/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   140
  --- a/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   141
  +++ b/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   142
  @@ -9,3 +9,6 @@
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   143
   Suggar
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   144
   Vinegar
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   145
   Oil
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   146
  +Bananos
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   147
  +Pear
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   148
  +Apple
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   149
654
c56109c9aebf tutorial: fix grammar, spelling, punctuation
Greg Ward <greg@gerg.ca>
parents: 652
diff changeset
   150
The faulty changeset is in the "draft" phase because it has not been exchanged with
c56109c9aebf tutorial: fix grammar, spelling, punctuation
Greg Ward <greg@gerg.ca>
parents: 652
diff changeset
   151
the outside. The first one has been exchanged and is "public" (immutable).
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   152
634
e763f7e94211 tutorial: glog is into core now
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 590
diff changeset
   153
  $ hg log -G
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   154
  @  d85de4546133 (draft): adding fruit
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   155
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   156
  o  4d5dc8187023 (draft): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   157
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   158
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   159
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   160
634
e763f7e94211 tutorial: glog is into core now
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 590
diff changeset
   161
hopefully. I can use `hg commit --amend` to rewrite my faulty changeset!
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   162
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   163
  $ sed -i'' -e s/Bananos/Banana/ shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   164
  $ hg diff
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   165
  diff --git a/shopping b/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   166
  --- a/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   167
  +++ b/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   168
  @@ -9,6 +9,6 @@
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   169
   Suggar
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   170
   Vinegar
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   171
   Oil
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   172
  -Bananos
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   173
  +Banana
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   174
   Pear
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   175
   Apple
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   176
  $ hg commit --amend
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   177
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   178
A new changeset with the right diff replace the wrong one.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   179
634
e763f7e94211 tutorial: glog is into core now
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 590
diff changeset
   180
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   181
  @  9d0363b81950 (draft): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   182
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   183
  o  4d5dc8187023 (draft): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   184
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   185
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   186
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   187
  $ hg export tip
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   188
  # HG changeset patch
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   189
  # User test
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   190
  # Date 0 0
726
06cd220141ba Adapt to human readable date in patch
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 696
diff changeset
   191
  #      Thu Jan 01 00:00:00 1970 +0000
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   192
  # Node ID 9d0363b81950646bc6ad1ec5de8b8197ea586541
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   193
  # Parent  4d5dc81870237d492284826e21840b2ca00e26d1
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   194
  adding fruit
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   195
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   196
  diff --git a/shopping b/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   197
  --- a/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   198
  +++ b/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   199
  @@ -9,3 +9,6 @@
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   200
   Suggar
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   201
   Vinegar
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   202
   Oil
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   203
  +Banana
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   204
  +Pear
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   205
  +Apple
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   206
654
c56109c9aebf tutorial: fix grammar, spelling, punctuation
Greg Ward <greg@gerg.ca>
parents: 652
diff changeset
   207
Getting rid of branchy history
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   208
----------------------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   209
768
b116de5dc70d tutorial: fix some various typo
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 767
diff changeset
   210
While I was working on my list. someone made a change remotly.
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   211
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   212
  $ cd ../remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   213
  $ hg up -q
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   214
  $ sed -i'' -e 's/Spam/Spam Spam Spam/' shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   215
  $ hg ci -m 'SPAM'
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   216
  $ cd ../local
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   217
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   218
I'll get this remote changeset when pulling
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   219
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   220
  $ hg pull remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   221
  pulling from $TESTTMP/remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   222
  searching for changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   223
  adding changesets
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   224
  adding manifests
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   225
  adding file changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   226
  added 1 changesets with 1 changes to 1 files (+1 heads)
625
e291e5271694 prepare for Full scale filtering !!!
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 590
diff changeset
   227
  (run 'hg heads' to see heads, 'hg merge' to merge)
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   228
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   229
I now have a new heads. Note that this remote head is immutable
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   230
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   231
  $ hg log -G
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   232
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   233
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   234
  | @  9d0363b81950 (draft): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   235
  | |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   236
  | o  4d5dc8187023 (draft): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   237
  |/
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   238
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   239
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   240
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   241
instead of merging my head with the new one. I'm going to rebase my work
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   242
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   243
  $ hg diff
769
e2a463e1e7c8 tutorial: use long form of argument for the sake of clarity
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 768
diff changeset
   244
  $ hg rebase --dest 9ca060c80d74 --source 4d5dc8187023
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   245
  merging shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   246
  merging shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   247
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   248
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   249
My local work is now rebased on the remote one.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   250
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   251
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   252
  @  41aff6a42b75 (draft): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   253
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   254
  o  dfd3a2d7691e (draft): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   255
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   256
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   257
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   258
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   259
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   260
654
c56109c9aebf tutorial: fix grammar, spelling, punctuation
Greg Ward <greg@gerg.ca>
parents: 652
diff changeset
   261
Removing changesets
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   262
------------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   263
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   264
I add new item to my list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   265
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   266
  $ cat >> shopping << EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   267
  > car
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   268
  > bus
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   269
  > plane
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   270
  > boat
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   271
  > EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   272
  $ hg ci -m 'transport'
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   273
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   274
  @  1125e39fbf21 (draft): transport
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   275
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   276
  o  41aff6a42b75 (draft): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   277
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   278
  o  dfd3a2d7691e (draft): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   279
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   280
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   281
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   282
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   283
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   284
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   285
I have a new commit but I realize that don't want it. (transport shop list does
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   286
not fit well in my standard shopping list)
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   287
771
126e31c7658b tutorial Clarify "." explanation
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 770
diff changeset
   288
  $ hg prune . # "." is for working directory parent
688
f2c3fd21fa63 prune: add an informative message about the number of pruned changesets
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 654
diff changeset
   289
  1 changesets pruned
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   290
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   291
  working directory now at 41aff6a42b75
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   292
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   293
The silly changeset is gone.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   294
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   295
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   296
  @  41aff6a42b75 (draft): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   297
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   298
  o  dfd3a2d7691e (draft): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   299
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   300
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   301
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   302
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   303
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   304
654
c56109c9aebf tutorial: fix grammar, spelling, punctuation
Greg Ward <greg@gerg.ca>
parents: 652
diff changeset
   305
Reordering changesets
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   306
------------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   307
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   308
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   309
We create two changesets.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   310
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   311
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   312
  $ cat >> shopping << EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   313
  > Shampoo
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   314
  > Toothbrush
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   315
  > ... More bathroom stuff to come
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   316
  > Towel
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   317
  > Soap
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   318
  > EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   319
  $ hg ci -m 'bathroom stuff' -q # XXX remove the -q
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   320
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   321
  $ sed -i'' -e 's/Spam/Spam Spam Spam/g' shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   322
  $ hg ci -m 'SPAM SPAM'
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   323
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   324
  @  fac207dec9f5 (draft): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   325
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   326
  o  10b8aeaa8cc8 (draft): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   327
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   328
  o  41aff6a42b75 (draft): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   329
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   330
  o  dfd3a2d7691e (draft): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   331
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   332
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   333
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   334
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   335
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   336
774
03844e1fbfe6 tutorial: fix note
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 773
diff changeset
   337
.. note:: We can't amend changeset 7e82d3f3c2cb or 9ca060c80d74 as they are immutable.
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   338
768
b116de5dc70d tutorial: fix some various typo
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 767
diff changeset
   339
 I now want to push to remote all my changes except the bathroom one, which I'm
b116de5dc70d tutorial: fix some various typo
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 767
diff changeset
   340
 not totally happy with yet. To be able to push "SPAM SPAM" I need a version of
b116de5dc70d tutorial: fix some various typo
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 767
diff changeset
   341
 "SPAM SPAM" which is not a child of "bathroom stuff"
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   342
772
27b3442f08d9 tutorial: use grab instead of rebase.
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 771
diff changeset
   343
You can use the 'grab' alias for that.
27b3442f08d9 tutorial: use grab instead of rebase.
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 771
diff changeset
   344
27b3442f08d9 tutorial: use grab instead of rebase.
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 771
diff changeset
   345
.. note: grab is an alias for `hg rebase --dest . --rev <target>; hg up <there>`
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   346
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   347
  $ hg up 'p1(10b8aeaa8cc8)' # going on "bathroom stuff" parent
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   348
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
772
27b3442f08d9 tutorial: use grab instead of rebase.
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 771
diff changeset
   349
  $ hg grab fac207dec9f5 # moving "SPAM SPAM" to the working directory parent
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   350
  merging shopping
747
9300f48786de test: prepare test for core changeset 9c78ed396075
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 743
diff changeset
   351
  ? files updated, 0 files merged, 0 files removed, 0 files unresolved (glob)
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   352
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   353
  @  a224f2a4fb9f (draft): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   354
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   355
  | o  10b8aeaa8cc8 (draft): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   356
  |/
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   357
  o  41aff6a42b75 (draft): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   358
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   359
  o  dfd3a2d7691e (draft): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   360
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   361
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   362
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   363
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   364
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   365
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   366
We have a new SPAM SPAM version without the bathroom stuff
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   367
634
e763f7e94211 tutorial: glog is into core now
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 590
diff changeset
   368
  $ grep Spam shopping  # enough spam
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   369
  Spam Spam Spam Spam Spam Spam Spam Spam Spam
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   370
  $ grep Toothbrush shopping # no Toothbrush
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   371
  [1]
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   372
  $ hg export .
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   373
  # HG changeset patch
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   374
  # User test
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   375
  # Date 0 0
726
06cd220141ba Adapt to human readable date in patch
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 696
diff changeset
   376
  #      Thu Jan 01 00:00:00 1970 +0000
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   377
  # Node ID a224f2a4fb9f9f828f608959912229d7b38b26de
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   378
  # Parent  41aff6a42b7578ec7ec3cb2041633f1ca43cca96
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   379
  SPAM SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   380
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   381
  diff --git a/shopping b/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   382
  --- a/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   383
  +++ b/shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   384
  @@ -1,4 +1,4 @@
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   385
  -Spam Spam Spam
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   386
  +Spam Spam Spam Spam Spam Spam Spam Spam Spam
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   387
   Whizzo butter
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   388
   Albatross
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   389
   Rat (rather a lot)
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   390
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   391
To make sure I do not push unready changeset by mistake I set the "bathroom
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   392
stuff" changeset in the secret phase.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   393
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   394
  $ hg phase --force --secret 10b8aeaa8cc8
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   395
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   396
we can now push our change:
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   397
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   398
  $ hg push remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   399
  pushing to $TESTTMP/remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   400
  searching for changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   401
  adding changesets
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   402
  adding manifests
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   403
  adding file changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   404
  added 3 changesets with 3 changes to 1 files
817
c2bf0eb727f1 exchange: only push the set of marker relevant to want we push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 803
diff changeset
   405
  OBSEXC: computing relevant nodes
c2bf0eb727f1 exchange: only push the set of marker relevant to want we push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 803
diff changeset
   406
  OBSEXC: computing markers relevant to 5 nodes
c2bf0eb727f1 exchange: only push the set of marker relevant to want we push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 803
diff changeset
   407
  OBSEXC: encoding 6 markers
c2bf0eb727f1 exchange: only push the set of marker relevant to want we push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 803
diff changeset
   408
  OBSEXC: sending 1 pushkey payload (609 bytes)
c2bf0eb727f1 exchange: only push the set of marker relevant to want we push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 803
diff changeset
   409
  OBSEXC: DONE
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   410
768
b116de5dc70d tutorial: fix some various typo
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 767
diff changeset
   411
for simplicity sake we get the bathroom change in line again
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   412
772
27b3442f08d9 tutorial: use grab instead of rebase.
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 771
diff changeset
   413
  $ hg grab 10b8aeaa8cc8
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   414
  merging shopping
747
9300f48786de test: prepare test for core changeset 9c78ed396075
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 743
diff changeset
   415
  ? files updated, 0 files merged, 0 files removed, 0 files unresolved (glob)
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   416
  $ hg phase --draft .
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   417
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   418
  @  75954b8cd933 (draft): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   419
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   420
  o  a224f2a4fb9f (public): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   421
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   422
  o  41aff6a42b75 (public): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   423
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   424
  o  dfd3a2d7691e (public): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   425
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   426
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   427
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   428
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   429
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   430
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   431
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   432
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   433
Splitting change
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   434
------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   435
767
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   436
This part is not written yet, but you can use either the `histedit` extension
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   437
of the `uncommit` command to splitting a change.
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   438
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   439
  $ hg help uncommit
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   440
  hg uncommit [OPTION]... [NAME]
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   441
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   442
  move changes from parent revision to working directory
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   443
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   444
      Changes to selected files in parent revision appear again as uncommitted
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   445
      changed in the working directory. A new revision without selected changes
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   446
      is created, becomes the new parent and obsoletes the previous one.
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   447
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   448
      The --include option specify pattern to uncommit The --exclude option
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   449
      specify pattern to keep in the commit
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   450
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   451
      Return 0 if changed files are uncommitted.
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   452
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   453
  options:
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   454
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   455
   -a --all                 uncommit all changes when no arguments given
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   456
   -I --include PATTERN [+] include names matching the given patterns
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   457
   -X --exclude PATTERN [+] exclude names matching the given patterns
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   458
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   459
  [+] marked option can be specified multiple times
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   460
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   461
  use "hg -v help uncommit" to show the global options
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   462
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   463
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   464
The edit command of histedit can be used to split changeset:
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   465
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   466
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   467
Collapsing change
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   468
------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   469
767
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   470
The tutorial part is not written yet but can use `hg fold`:
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   471
767
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   472
  $ hg help fold
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   473
  hg fold rev
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   474
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   475
  Fold multiple revisions into a single one
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   476
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   477
      Revision from your current working directory to the specified one are fold
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   478
      as a new one replacing the other
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   479
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   480
      you can alternatively use --rev to explicitly specify revision to be fold
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   481
      ignoring the current working directory parent.
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   482
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   483
  options:
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   484
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   485
   -r --rev VALUE [+] explicitly specify the full set of revision to fold
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   486
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   487
  [+] marked option can be specified multiple times
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   488
  
01a270481a61 tutorial Display the help of appropriate command in section that need writting
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 766
diff changeset
   489
  use "hg -v help fold" to show the global options
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   490
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   491
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   492
-----------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   493
Collaboration
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   494
-----------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   495
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   496
768
b116de5dc70d tutorial: fix some various typo
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 767
diff changeset
   497
sharing mutable changesets
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   498
----------------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   499
768
b116de5dc70d tutorial: fix some various typo
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 767
diff changeset
   500
To share mutable changesets with others, just check that the repo you interact
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   501
with is "not publishing". Otherwise you will get the previously observe
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   502
behavior where exchanged changeset are automatically published.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   503
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   504
  $ cd ../remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   505
  $ hg -R ../local/ showconfig phases
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   506
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   507
the localrepo does not have any specific configuration for `phases.publish`. It
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   508
is ``true`` by default.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   509
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   510
  $ hg pull local
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   511
  pulling from $TESTTMP/local
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   512
  searching for changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   513
  adding changesets
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   514
  adding manifests
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   515
  adding file changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   516
  added 1 changesets with 1 changes to 1 files
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   517
  (run 'hg update' to get a working copy)
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   518
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   519
  o  75954b8cd933 (public): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   520
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   521
  o  a224f2a4fb9f (public): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   522
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   523
  o  41aff6a42b75 (public): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   524
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   525
  o  dfd3a2d7691e (public): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   526
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   527
  @  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   528
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   529
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   530
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   531
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   532
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   533
773
fc8034069fe1 tutorial: warn about rollback beeing obsolete
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 772
diff changeset
   534
We do not want to publish the "bathroom changeset". Let's rollback the last transaction.
fc8034069fe1 tutorial: warn about rollback beeing obsolete
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 772
diff changeset
   535
fc8034069fe1 tutorial: warn about rollback beeing obsolete
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 772
diff changeset
   536
.. Warning: Rollback is actually a dangerous kind of internal command that is deprecated and should not be exposed to user. Please forget you read about it until someone fix this tutorial.
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   537
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   538
  $ hg rollback
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   539
  repository tip rolled back to revision 4 (undo pull)
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   540
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   541
  o  a224f2a4fb9f (public): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   542
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   543
  o  41aff6a42b75 (public): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   544
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   545
  o  dfd3a2d7691e (public): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   546
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   547
  @  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   548
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   549
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   550
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   551
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   552
Let's make the local repo "non publishing"
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   553
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   554
  $ echo '[phases]' >> ../local/.hg/hgrc
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   555
  $ echo 'publish=false' >> ../local/.hg/hgrc
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   556
  $ echo '[phases]' >> .hg/hgrc
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   557
  $ echo 'publish=false' >> .hg/hgrc
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   558
  $ hg showconfig phases
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   559
  phases.publish=false
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   560
  $ hg -R ../local/ showconfig phases
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   561
  phases.publish=false
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   562
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   563
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   564
I can now exchange mutable changeset between "remote" and "local" repository.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   565
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   566
  $ hg pull local
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   567
  pulling from $TESTTMP/local
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   568
  searching for changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   569
  adding changesets
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   570
  adding manifests
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   571
  adding file changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   572
  added 1 changesets with 1 changes to 1 files
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   573
  (run 'hg update' to get a working copy)
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   574
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   575
  o  75954b8cd933 (draft): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   576
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   577
  o  a224f2a4fb9f (public): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   578
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   579
  o  41aff6a42b75 (public): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   580
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   581
  o  dfd3a2d7691e (public): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   582
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   583
  @  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   584
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   585
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   586
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   587
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   588
Rebasing unstable change after pull
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   589
----------------------------------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   590
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   591
Remotely someone add a new changeset on top of the mutable "bathroom" on.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   592
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   593
  $ hg up 75954b8cd933 -q
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   594
  $ cat >> shopping << EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   595
  > Giraffe
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   596
  > Rhino
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   597
  > Lion
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   598
  > Bear
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   599
  > EOF
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   600
  $ hg ci -m 'animals'
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   601
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   602
But at the same time, locally, this same "bathroom changeset" was updated.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   603
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   604
  $ cd ../local
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   605
  $ hg up 75954b8cd933 -q
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   606
  $ sed -i'' -e 's/... More bathroom stuff to come/Bath Robe/' shopping
637
fdbbc9b2fca2 tutorial: use commit --amend when possible
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 636
diff changeset
   607
  $ hg commit --amend
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   608
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   609
  @  a44c85f957d3 (draft): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   610
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   611
  o  a224f2a4fb9f (public): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   612
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   613
  o  41aff6a42b75 (public): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   614
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   615
  o  dfd3a2d7691e (public): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   616
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   617
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   618
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   619
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   620
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   621
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   622
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   623
When we pull from remote again we get an unstable state!
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   624
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   625
  $ hg pull remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   626
  pulling from $TESTTMP/remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   627
  searching for changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   628
  adding changesets
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   629
  adding manifests
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   630
  adding file changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   631
  added 1 changesets with 1 changes to 1 files (+1 heads)
625
e291e5271694 prepare for Full scale filtering !!!
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 590
diff changeset
   632
  (run 'hg heads' to see heads, 'hg merge' to merge)
486
2111c655b4f5 fix typo
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 466
diff changeset
   633
  1 new unstable changesets
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   634
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   635
654
c56109c9aebf tutorial: fix grammar, spelling, punctuation
Greg Ward <greg@gerg.ca>
parents: 652
diff changeset
   636
The new changeset "animal" is based on an old changeset of "bathroom". You can
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   637
see both version showing up in the log.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   638
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   639
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   640
  o  bf1b0d202029 (draft): animals
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   641
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   642
  | @  a44c85f957d3 (draft): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   643
  | |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   644
  x |  75954b8cd933 (draft): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   645
  |/
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   646
  o  a224f2a4fb9f (public): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   647
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   648
  o  41aff6a42b75 (public): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   649
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   650
  o  dfd3a2d7691e (public): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   651
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   652
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   653
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   654
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   655
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   656
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   657
The older version 75954b8cd933 never ceased to exist in the local repo. It was
654
c56109c9aebf tutorial: fix grammar, spelling, punctuation
Greg Ward <greg@gerg.ca>
parents: 652
diff changeset
   658
just hidden and excluded from pull and push.
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   659
654
c56109c9aebf tutorial: fix grammar, spelling, punctuation
Greg Ward <greg@gerg.ca>
parents: 652
diff changeset
   660
.. note:: In hgview there is a nice dotted relation highlighting a44c85f957d3 as a new version of 75954b8cd933. this is not yet ported to ``hg log -G``.
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   661
654
c56109c9aebf tutorial: fix grammar, spelling, punctuation
Greg Ward <greg@gerg.ca>
parents: 652
diff changeset
   662
There is now an **unstable** changeset in this history. Mercurial will refuse to
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   663
share it with the outside:
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   664
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   665
  $ hg push other
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   666
  pushing to $TESTTMP/other
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   667
  searching for changes
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   668
  abort: push includes unstable changeset: bf1b0d202029!
492
7ecd41520dae rename `stabilize` to `evolve`
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 486
diff changeset
   669
  (use 'hg evolve' to get a stable history or --force to ignore warnings)
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   670
  [255]
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   671
 
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   672
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   673
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   674
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   675
To resolve this unstable state, you need to rebase bf1b0d202029 onto
768
b116de5dc70d tutorial: fix some various typo
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 767
diff changeset
   676
a44c85f957d3. The `hg evolve` command will do this for you.
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   677
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   678
It has a --dry-run option to only suggest the next move.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   679
492
7ecd41520dae rename `stabilize` to `evolve`
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 486
diff changeset
   680
  $ hg evolve --dry-run
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   681
  move:[15] animals
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   682
  atop:[14] bathroom stuff
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   683
  hg rebase -r bf1b0d202029 -d a44c85f957d3
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   684
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   685
Let's do it
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   686
639
bc2527223350 tutorial: use evolve directly
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 638
diff changeset
   687
  $ hg evolve
bc2527223350 tutorial: use evolve directly
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 638
diff changeset
   688
  move:[15] animals
bc2527223350 tutorial: use evolve directly
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 638
diff changeset
   689
  atop:[14] bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   690
  merging shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   691
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   692
The old version of bathroom is hidden again.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   693
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   694
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   695
  @  ee942144f952 (draft): animals
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   696
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   697
  o  a44c85f957d3 (draft): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   698
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   699
  o  a224f2a4fb9f (public): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   700
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   701
  o  41aff6a42b75 (public): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   702
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   703
  o  dfd3a2d7691e (public): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   704
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   705
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   706
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   707
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   708
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   709
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   710
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   711
We can push this evolution to remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   712
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   713
  $ hg push remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   714
  pushing to $TESTTMP/remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   715
  searching for changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   716
  adding changesets
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   717
  adding manifests
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   718
  adding file changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   719
  added 2 changesets with 2 changes to 1 files (+1 heads)
817
c2bf0eb727f1 exchange: only push the set of marker relevant to want we push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 803
diff changeset
   720
  OBSEXC: computing relevant nodes
c2bf0eb727f1 exchange: only push the set of marker relevant to want we push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 803
diff changeset
   721
  OBSEXC: computing markers relevant to 7 nodes
c2bf0eb727f1 exchange: only push the set of marker relevant to want we push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 803
diff changeset
   722
  OBSEXC: encoding 10 markers
c2bf0eb727f1 exchange: only push the set of marker relevant to want we push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 803
diff changeset
   723
  OBSEXC: sending 1 pushkey payload (1004 bytes)
c2bf0eb727f1 exchange: only push the set of marker relevant to want we push
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 803
diff changeset
   724
  OBSEXC: DONE
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   725
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   726
remote get a warning that current working directory is based on an obsolete changeset
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   727
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   728
  $ cd ../remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   729
  $ hg pull local # we up again to trigger the warning. it was displayed during the push
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   730
  pulling from $TESTTMP/local
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   731
  searching for changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   732
  no changes found
743
af74a5cdf96b conform to the Mercurial custom of lowercase messages
Dan Villiom Podlaski Christiansen <danchr@gmail.com>
parents: 726
diff changeset
   733
  working directory parent is obsolete!
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   734
750
ddbea2fdee5e evolve: allow updating to the successor if the parent is obsolete
Dan Villiom Podlaski Christiansen <dan@cabo.dk>
parents: 747
diff changeset
   735
now let's see where we are, and update to the successor
ddbea2fdee5e evolve: allow updating to the successor if the parent is obsolete
Dan Villiom Podlaski Christiansen <dan@cabo.dk>
parents: 747
diff changeset
   736
ddbea2fdee5e evolve: allow updating to the successor if the parent is obsolete
Dan Villiom Podlaski Christiansen <dan@cabo.dk>
parents: 747
diff changeset
   737
  $ hg parents
ddbea2fdee5e evolve: allow updating to the successor if the parent is obsolete
Dan Villiom Podlaski Christiansen <dan@cabo.dk>
parents: 747
diff changeset
   738
  bf1b0d202029 (draft): animals
ddbea2fdee5e evolve: allow updating to the successor if the parent is obsolete
Dan Villiom Podlaski Christiansen <dan@cabo.dk>
parents: 747
diff changeset
   739
  working directory parent is obsolete!
ddbea2fdee5e evolve: allow updating to the successor if the parent is obsolete
Dan Villiom Podlaski Christiansen <dan@cabo.dk>
parents: 747
diff changeset
   740
  $ hg evolve
ddbea2fdee5e evolve: allow updating to the successor if the parent is obsolete
Dan Villiom Podlaski Christiansen <dan@cabo.dk>
parents: 747
diff changeset
   741
  update:[8] animals
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   742
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   743
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   744
Relocating unstable change after prune
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   745
----------------------------------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   746
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   747
The remote guy keep working
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   748
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   749
  $ sed -i'' -e 's/Spam/Spam Spam Spam Spam/g' shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   750
  $ hg commit -m "SPAM SPAM SPAM"
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   751
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   752
I'm pulling its work locally.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   753
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   754
  $ cd ../local
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   755
  $ hg pull remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   756
  pulling from $TESTTMP/remote
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   757
  searching for changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   758
  adding changesets
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   759
  adding manifests
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   760
  adding file changes
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   761
  added 1 changesets with 1 changes to 1 files
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   762
  (run 'hg update' to get a working copy)
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   763
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   764
  o  99f039c5ec9e (draft): SPAM SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   765
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   766
  @  ee942144f952 (draft): animals
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   767
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   768
  o  a44c85f957d3 (draft): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   769
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   770
  o  a224f2a4fb9f (public): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   771
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   772
  o  41aff6a42b75 (public): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   773
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   774
  o  dfd3a2d7691e (public): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   775
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   776
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   777
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   778
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   779
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   780
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   781
In the mean time I noticed you can't buy animals in a super market and I prune the animal changeset:
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   782
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   783
  $ hg prune ee942144f952
688
f2c3fd21fa63 prune: add an informative message about the number of pruned changesets
Pierre-Yves David <pierre-yves.david@ens-lyon.org>
parents: 654
diff changeset
   784
  1 changesets pruned
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   785
  1 files updated, 0 files merged, 0 files removed, 0 files unresolved
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   786
  working directory now at a44c85f957d3
486
2111c655b4f5 fix typo
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 466
diff changeset
   787
  1 new unstable changesets
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   788
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   789
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   790
The animals changeset is still displayed because the "SPAM SPAM SPAM" changeset
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   791
is neither dead or obsolete.  My repository is in an unstable state again.
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   792
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   793
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   794
  o  99f039c5ec9e (draft): SPAM SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   795
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   796
  x  ee942144f952 (draft): animals
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   797
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   798
  @  a44c85f957d3 (draft): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   799
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   800
  o  a224f2a4fb9f (public): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   801
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   802
  o  41aff6a42b75 (public): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   803
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   804
  o  dfd3a2d7691e (public): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   805
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   806
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   807
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   808
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   809
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   810
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   811
  $ hg log -r 'unstable()'
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   812
  99f039c5ec9e (draft): SPAM SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   813
636
27c890b4f864 evolve: make evolve smarter
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 635
diff changeset
   814
  $ hg evolve
466
b98490b689a5 stabilize: handle killed changeset in stabilize.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 441
diff changeset
   815
  move:[17] SPAM SPAM SPAM
b98490b689a5 stabilize: handle killed changeset in stabilize.
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 441
diff changeset
   816
  atop:[14] bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   817
  merging shopping
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   818
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   819
  $ hg log -G
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   820
  @  40aa40daeefb (draft): SPAM SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   821
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   822
  o  a44c85f957d3 (draft): bathroom stuff
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   823
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   824
  o  a224f2a4fb9f (public): SPAM SPAM
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   825
  |
640
629ec7f612aa tutorial: second replacement of hg amend by commit --amend
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 639
diff changeset
   826
  o  41aff6a42b75 (public): adding fruit
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   827
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   828
  o  dfd3a2d7691e (public): adding condiment
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   829
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   830
  o  9ca060c80d74 (public): SPAM
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   831
  |
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   832
  o  7e82d3f3c2cb (public): Monthy Python Shopping list
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   833
  
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   834
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   835
770
303d27c76021 tutorial: update divergent changeset section
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 769
diff changeset
   836
Handling Divergent amend
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   837
----------------------------------------------
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   838
803
b96d51a357bd test: get rid of all reference to conflicting changesets
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 774
diff changeset
   839
We can detect that multiple diverging amendments have been made.
770
303d27c76021 tutorial: update divergent changeset section
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 769
diff changeset
   840
The `evolve` command can solve this situation. But all corner case are not
303d27c76021 tutorial: update divergent changeset section
Pierre-Yves David <pierre-yves.david@fb.com>
parents: 769
diff changeset
   841
handled now.
441
d702f0d26c6a obsolete: remove debugsuccessors
Pierre-Yves David <pierre-yves.david@logilab.fr>
parents: 163
diff changeset
   842
654
c56109c9aebf tutorial: fix grammar, spelling, punctuation
Greg Ward <greg@gerg.ca>
parents: 652
diff changeset
   843
This section needs to be written.