Rev 5906: (spiv) Merge lp:bzr/2.3, in file:///home/pqm/archives/thelove/bzr/%2Btrunk/

Canonical.com Patch Queue Manager pqm at pqm.ubuntu.com
Fri May 20 21:28:19 UTC 2011


At file:///home/pqm/archives/thelove/bzr/%2Btrunk/

------------------------------------------------------------
revno: 5906 [merge]
revision-id: pqm at pqm.ubuntu.com-20110520212809-ugt47o73t2ntwbmw
parent: pqm at pqm.ubuntu.com-20110520151232-ktqtldpnygirg6zk
parent: andrew.bennetts at canonical.com-20110520172726-7cezrw49x96kbom8
committer: Canonical.com Patch Queue Manager <pqm at pqm.ubuntu.com>
branch nick: +trunk
timestamp: Fri 2011-05-20 21:28:09 +0000
message:
  (spiv) Merge lp:bzr/2.3,
   including improvements to stacking docs in the User Guide. (Andrew Bennetts)
modified:
  doc/en/release-notes/bzr-2.3.txt NEWS-20050323055033-4e00b5db738777ff
  doc/en/user-guide/stacked.txt  stacked.txt-20080711023247-4uh9oovoka0sze8b-1
=== modified file 'doc/en/release-notes/bzr-2.3.txt'
--- a/doc/en/release-notes/bzr-2.3.txt	2011-05-17 20:58:43 +0000
+++ b/doc/en/release-notes/bzr-2.3.txt	2011-05-20 17:27:26 +0000
@@ -38,6 +38,10 @@
 
 .. Improved or updated documentation.
 
+* Updated the "Using stacked branches" section of the user guide to
+  describe committing to stacked branches and expanded its discussion of
+  pushing a stcked branch.  (Andrew Bennetts)
+
 API Changes
 ***********
 

=== modified file 'doc/en/user-guide/stacked.txt'
--- a/doc/en/user-guide/stacked.txt	2011-04-06 04:58:43 +0000
+++ b/doc/en/user-guide/stacked.txt	2011-05-20 17:27:26 +0000
@@ -74,46 +74,55 @@
 This creates a new branch at ``my-url`` that is stacked on ``reference-url``
 and only contains the revisions in the current branch that are not already
 in the branch at ``reference-url``. In particular, ``my-url`` and
-``reference-url`` can be on the same host, and the ``--stacked`` option
+``reference-url`` can be on the same host, and the ``--stacked-on`` option
 can be used additionally to inform ``push`` to reference the
 revisions in ``reference-url``. For example::
 
-  bzr push --stacked-on bzr+ssh://host/project --stacked bzr+ssh://host/user/stacked-branch
+  bzr push --stacked-on bzr+ssh://host/project bzr+ssh://host/user/stacked-branch
 
 This usage fits the scenario described in the Motivation section.
 
-
-.. The following text is hidden because bug 375013 breaks the example.
-   When bug 375013 is fixed, we should unhide this text.
-      - Andrew Bennetts, 10 March 2010
-
-.. If the local branch was created as a stacked branch, then you can
-.. use the ``--stacked`` option to ``push`` and the *stacked-on* location
-.. will be implicit. For example::
-.. 
-..   bzr branch --stacked source-url my-dir
-..   cd my-dir
-..   (hack, hack, hack)
-..   bzr commit -m "fix bug"
-..   bzr push --stacked
+You can also use the ``--stacked`` option without specifying ``--stacked-on``.
+This will automatically set the *stacked-on* location to the parent branch of
+the branch you are pushing (or its ``public_location`` if configured).  For
+example::
+
+  bzr branch source-url my-dir
+  cd my-dir
+  (hack, hack, hack)
+  bzr commit -m "fix bug"
+  bzr push --stacked
+
+You can combine ``bzr branch --stacked`` and ``bzr push --stacked`` to work on a
+branch without downloading or uploading the whole history::
+
+  bzr branch --stacked source-url my-dir
+  cd my-dir
+  (hack, hack, hack)
+  bzr commit -m "fix bug"
+  bzr push --stacked
 
 
 Limitations of stacked branches
 -------------------------------
 
-Currently, you cannot commit to a stacked branch, due to `bug 375013`_.
-
-.. _bug 375013: https://bugs.launchpad.net/bzr/+bug/375013
-
-The important thing to remember about a stacked branch is that the
-stacked-on branch needs to be available for almost all operations. This is
-not an issue when both branches are local or both branches are on the
-same server.
+The important thing to remember about a stacked branch is that the stacked-on
+branch needs to be accessible for almost all operations.  This is not an issue
+when both branches are local, or when both branches are on the same server and
+the stacked-on location is a relative path.  But clearly a branch hosted on a
+server with a stacked-on location of ``file:///...`` is not going to work for
+anyone except the user that originally pushed it.  It's a good idea to configure
+``public_location`` to help prevent that.
 
 Similarly, because most of the history is stored in the stacked-on repository,
 operations like ``bzr log`` can be slower when the stacked-on repository is
 accessed via a network.
 
+If a stacked branch is in a format older than 2a, you cannot commit to it due to
+`bug 375013`_.
+
+.. _bug 375013: https://bugs.launchpad.net/bzr/+bug/375013
+
 
 Changing branch stacking
 ------------------------




More information about the bazaar-commits mailing list