Merge lp:~bialix/bzr-colo/checkout into lp:bzr-colo

Proposed by Alexander Belchenko
Status: Merged
Merged at revision: not available
Proposed branch: lp:~bialix/bzr-colo/checkout
Merge into: lp:bzr-colo
Diff against target: 197 lines (+28/-27)
4 files modified
__init__.py (+2/-2)
commands.py (+2/-1)
tests/test_colo.py (+11/-11)
tutorial.py (+13/-13)
To merge this branch: bzr merge lp:~bialix/bzr-colo/checkout
Reviewer Review Type Date Requested Status
Neil Martinsen-Burrell Pending
Review via email: mp+18760@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Alexander Belchenko (bialix) wrote :

This patch changed name of colo-clone command to colo-checkout, because actually help and tutorial talk about creating new checkout for existing colo workspace instead of cloning (copy) workspace itself. I think clone is wrong word here and misleading.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file '__init__.py'
2--- __init__.py 2010-01-14 12:55:12 +0000
3+++ __init__.py 2010-02-06 14:09:14 +0000
4@@ -31,7 +31,7 @@
5 * colo-branch
6 * colo-branches
7 * colo-fetch
8- * colo-clone
9+ * colo-checkout
10 * colo-prune
11 * colo-clean
12 * colo-ify
13@@ -91,7 +91,7 @@
14 ('cmd_colo_branch', []),
15 ('cmd_colo_branches', []),
16 ('cmd_colo_fetch', []),
17- ('cmd_colo_clone', []),
18+ ('cmd_colo_checkout', ['colo-co']),
19 ('cmd_colo_prune', []),
20 ('cmd_colo_clean', []),
21 ('cmd_colo_ify', []),
22
23=== modified file 'commands.py'
24--- commands.py 2010-01-14 18:34:54 +0000
25+++ commands.py 2010-02-06 14:09:14 +0000
26@@ -256,7 +256,7 @@
27 remember=True)
28
29
30-class cmd_colo_clone(commands.Command):
31+class cmd_colo_checkout(commands.Command):
32
33 """Create a checkout of this branch in a new directory.
34
35@@ -266,6 +266,7 @@
36 the new checkout is switched to that new branch.
37 """
38
39+ alises = ['colo-co']
40 takes_args = ['to_directory']
41 takes_options = [
42 option.Option('create',
43
44=== modified file 'tests/test_colo.py'
45--- tests/test_colo.py 2010-02-05 16:31:24 +0000
46+++ tests/test_colo.py 2010-02-06 14:09:14 +0000
47@@ -380,18 +380,18 @@
48 """)
49
50
51-class TestColoClone(script.TestCaseWithTransportAndScript):
52+class TestColoCheckout(script.TestCaseWithTransportAndScript):
53
54- def test_clone(self):
55+ def test_checkout(self):
56 self.run_script("""
57 $ bzr colo-init branch
58 $ cd branch
59-$ bzr colo-clone ../branch2
60+$ bzr colo-checkout ../branch2
61 $ cd ../branch2
62 $ cat .bzr/README
63 """)
64
65- def test_clone_example(self):
66+ def test_checkout_example(self):
67 self.run_script("""
68 $ bzr colo-init branch
69 $ cd branch
70@@ -401,16 +401,16 @@
71 trunk
72 $ bzr switch trunk
73 $ bzr colo-branch fix-unicode-normalization
74-$ bzr colo-clone ../fix-unicode-normalization
75+$ bzr colo-checkout ../fix-unicode-normalization
76 $ cd ../fix-unicode-normalization
77 $ cat .bzr/README
78 """)
79
80- def test_clone_create(self):
81+ def test_checkout_create(self):
82 self.run_script("""
83 $ bzr colo-init branch
84 $ cd branch
85-$ bzr colo-clone --create ../fix1
86+$ bzr colo-checkout --create ../fix1
87 $ bzr colo-branches
88 fix1
89 * trunk
90@@ -425,10 +425,10 @@
91 trunk
92 """)
93
94- def test_clone_in_directory(self):
95+ def test_checkout_in_directory(self):
96 self.run_script("""
97 $ bzr colo-init
98-$ bzr colo-clone tree
99+$ bzr colo-checkout tree
100 $ cd tree
101 $ cat .bzr/README
102 $ bzr nick
103@@ -694,12 +694,12 @@
104 trunk
105 """)
106
107- def test_clone(self):
108+ def test_checkout(self):
109 self.run_script("""
110 $ bzr colo-init test
111 $ cd test
112 $ bzr colo-branch a/b
113-$ bzr colo-clone ../b-checkout
114+$ bzr colo-checkout ../b-checkout
115 $ cd ../b-checkout
116 $ bzr switch colo:trunk
117 """)
118
119=== modified file 'tutorial.py'
120--- tutorial.py 2010-01-14 12:55:12 +0000
121+++ tutorial.py 2010-02-06 14:09:14 +0000
122@@ -116,7 +116,7 @@
123
124 Sometimes it is nice to be able to make a second working tree for the same
125 colocated workspace, for example to work on a second bug fix in parallel.
126-This plugin provides the ``colo-clone`` command which creates a second
127+This plugin provides the ``colo-checkout`` command which creates a second
128 checkout of the current branch in the specified directory. Often, the
129 specified directory will be a sibling of the current workspace. For example::
130
131@@ -124,7 +124,7 @@
132 fix-eol-bug
133 * trunk
134 $ bzr colo-branch fix-unicode-normalization # creates a colocated branch
135- $ bzr colo-clone ../fix-unicode-normalization
136+ $ bzr colo-checkout ../fix-unicode-normalization
137 $ cd ../fix-unicode-normalization
138 $ bzr colo-branches
139 fix-eol-bug
140@@ -140,13 +140,13 @@
141 $ bzr diff --old=colo:trunk
142
143 Since creating a new colocated branch for work in a new checkout is a common
144-operation, the ``colo-clone`` command takes a ``--create`` option to indicate
145-that a new colocated branch should be created and then the new checkout should
146-be switched to that new branch. The name of the new branch comes from the
147-basename of the directory that is being created. For example, we could
148-shorten the above example as::
149+operation, the ``colo-checkout`` command takes a ``--create`` option
150+to indicate that a new colocated branch should be created and then the new
151+checkout should be switched to that new branch. The name of the new branch
152+comes from the basename of the directory that is being created.
153+For example, we could shorten the above example as::
154
155- $ bzr colo-clone --create ../fix-unicode-normalization
156+ $ bzr colo-checkout --create ../fix-unicode-normalization
157
158 Fetching an Existing Project
159 ----------------------------
160@@ -309,7 +309,7 @@
161 re-create. This can be a disadvantage when we want to have two separate
162 working trees, for example to compare two sets of files or to maintain a
163 working tree that is up to date with a particular branch. We can do this
164-using a colocated workspace and the ``colo-clone`` command.
165+using a colocated workspace and the ``colo-checkout`` command.
166
167 For example, when developing a project such as Bazaar, it can be important to
168 have a pristine copy of the trunk from which to run Bazaar while developing so
169@@ -320,7 +320,7 @@
170
171 $ bzr colo-fetch lp:bzr bzr
172 $ cd bzr
173- $ bzr colo-clone ../bzr.dev
174+ $ bzr colo-checkout ../bzr.dev
175 $ bzr colo-branch fix-doc-bugs
176 $ bzr colo-branches
177 * fix-doc-bugs
178@@ -328,8 +328,8 @@
179 $ ../bzr.dev/bzr --version # this runs the trunk version of bzr
180 $ ./bzr --version # this runs the version in the fix-doc-bugs branch
181
182-Another use for the ``colo-clone`` command is to create a second working tree
183-to do some work without interrupting the work that is happening in the
184+Another use for the ``colo-checkout`` command is to create a second working
185+tree to do some work without interrupting the work that is happening in the
186 colocated workspace (although a judicious use of ``bzr shelve`` can sometimes
187 make this unnecessary). Here is an example that uses the ``--create`` option
188 to create a new branch and make a new checkout of it::
189@@ -337,7 +337,7 @@
190 $ bzr colo-branches
191 * fix-doc-bugs
192 trunk
193- $ bzr colo-clone --create ../urgent-fix
194+ $ bzr colo-checkout --create ../urgent-fix
195 $ bzr colo-branches
196 * fix-doc-bugs
197 trunk

Subscribers

People subscribed via source and target branches