Patchwork [10,of,10,V8] help: add documentation about bookmark part

login
register
mail settings
Submitter Stanislau Hlebik
Date Nov. 12, 2016, 8:20 p.m.
Message ID <d1bfcb4a1594060275db.1478982000@dev1918.lla1.facebook.com>
Download mbox | patch
Permalink /patch/17524/
State Superseded
Headers show

Comments

Stanislau Hlebik - Nov. 12, 2016, 8:20 p.m.
# HG changeset patch
# User Stanislau Hlebik <stash@fb.com>
# Date 1478980606 28800
#      Sat Nov 12 11:56:46 2016 -0800
# Branch stable
# Node ID d1bfcb4a1594060275db040e6534fd262c5a43ec
# Parent  dd7caf9f799c4c8e012afca214683159645cc931
help: add documentation about bookmark part

Patch

diff --git a/mercurial/help/internals/bundles.txt b/mercurial/help/internals/bundles.txt
--- a/mercurial/help/internals/bundles.txt
+++ b/mercurial/help/internals/bundles.txt
@@ -92,3 +92,32 @@ 
 ``HGS1UN`` support was added as an experimental feature in version 3.6
 (released November 2015) as part of the initial offering of the *clone
 bundles* feature.
+
+Bundle2 parts
+=============
+
+Bundle2 may contain many different pieces of information. These pieces are
+called parts.
+
+Bookmarks part
+--------------
+
+This part contains information about bookmarks. Part consists of many entries.
+Each entry describes one bookmark. Entry format:
+
+4 bytes
+  bookmark size
+1 byte
+  boolean. True if node is empty, False otherwise
+20 bytes (optional)
+  node. Present only if previous field is True
+
+Modes:
+
+1. 'ignore' - do not apply any changes to the repo, just decode the passed
+bookmarks. Will be used to list bookmarks in remote repo.
+2. 'diverge' - apply bookmark changes to the repo. Create divergent bookmarks if
+there is a non-fastforward move. Will be used during pull.
+3. 'apply' - apply bookmark changes to the repo. Overwrite current bookmark node
+if there is a non-fastforward move. Will be used during push.
+