Rev 5638: Rename the command to 'repair-workingtree' as mentioned by vila. in http://bazaar.launchpad.net/~jameinel/bzr/2.4-reset-checkout
John Arbash Meinel
john at arbash-meinel.com
Thu Jan 27 16:27:16 UTC 2011
At http://bazaar.launchpad.net/~jameinel/bzr/2.4-reset-checkout
------------------------------------------------------------
revno: 5638
revision-id: john at arbash-meinel.com-20110127162705-50yqwnbkvcrw0yfl
parent: john at arbash-meinel.com-20110125232146-axecjegxo7xwc79y
committer: John Arbash Meinel <john at arbash-meinel.com>
branch nick: 2.4-reset-checkout
timestamp: Thu 2011-01-27 10:27:05 -0600
message:
Rename the command to 'repair-workingtree' as mentioned by vila.
-------------- next part --------------
=== modified file 'bzrlib/builtins.py'
--- a/bzrlib/builtins.py 2011-01-25 23:21:46 +0000
+++ b/bzrlib/builtins.py 2011-01-27 16:27:05 +0000
@@ -482,7 +482,7 @@
d.destroy_workingtree()
-class cmd_reset_workingtree(Command):
+class cmd_repair_workingtree(Command):
__doc__ = """Reset the working tree state file.
This is not meant to be used normally, but more as a way to recover from
=== modified file 'bzrlib/tests/blackbox/__init__.py'
--- a/bzrlib/tests/blackbox/__init__.py 2011-01-24 22:57:04 +0000
+++ b/bzrlib/tests/blackbox/__init__.py 2011-01-27 16:27:05 +0000
@@ -99,7 +99,7 @@
'test_remove',
'test_re_sign',
'test_remove_tree',
- 'test_reset_workingtree',
+ 'test_repair_workingtree',
'test_resolve',
'test_revert',
'test_revno',
=== renamed file 'bzrlib/tests/blackbox/test_reset_workingtree.py' => 'bzrlib/tests/blackbox/test_repair_workingtree.py'
--- a/bzrlib/tests/blackbox/test_reset_workingtree.py 2011-01-25 23:21:46 +0000
+++ b/bzrlib/tests/blackbox/test_repair_workingtree.py 2011-01-27 16:27:05 +0000
@@ -21,7 +21,7 @@
from bzrlib.tests import TestCaseWithTransport
-class TestResetWorkingTree(TestCaseWithTransport):
+class TestRepairWorkingTree(TestCaseWithTransport):
def break_dirstate(self, tree, completely=False):
"""Write garbage into the dirstate file."""
@@ -54,44 +54,44 @@
tree.commit('first')
return tree
- def test_reset_refuses_uncorrupted(self):
+ def test_repair_refuses_uncorrupted(self):
tree = self.make_initial_tree()
# If the tree doesn't appear to be corrupt, we refuse, but prompt the
# user to let them know that:
- # a) they may want to use 'bzr revert' instead of reset-workingtree
+ # a) they may want to use 'bzr revert' instead of repair-workingtree
# b) they can use --force if they really want to do this
self.run_bzr_error(['The tree does not appear to be corrupt',
'"bzr revert"',
'--force'],
- 'reset-workingtree -d tree')
+ 'repair-workingtree -d tree')
- def test_reset_forced(self):
+ def test_repair_forced(self):
tree = self.make_initial_tree()
tree.rename_one('dir', 'alt_dir')
self.assertIsNot(None, tree.path2id('alt_dir'))
- self.run_bzr('reset-workingtree -d tree --force')
+ self.run_bzr('repair-workingtree -d tree --force')
# This requires the tree has reloaded the working state
self.assertIs(None, tree.path2id('alt_dir'))
self.failUnlessExists('tree/alt_dir')
- def test_reset_corrupted_dirstate(self):
+ def test_repair_corrupted_dirstate(self):
tree = self.make_initial_tree()
self.break_dirstate(tree)
- self.run_bzr('reset-workingtree -d tree')
+ self.run_bzr('repair-workingtree -d tree')
tree = workingtree.WorkingTree.open('tree')
# At this point, check should be happy
tree.check_state()
- def test_reset_naive_destroyed_fails(self):
+ def test_repair_naive_destroyed_fails(self):
tree = self.make_initial_tree()
self.break_dirstate(tree, completely=True)
self.run_bzr_error(['the header appears corrupt, try passing'],
- 'reset-workingtree -d tree')
+ 'repair-workingtree -d tree')
- def test_reset_destroyed_with_revs_passes(self):
+ def test_repair_destroyed_with_revs_passes(self):
tree = self.make_initial_tree()
self.break_dirstate(tree, completely=True)
- self.run_bzr('reset-workingtree -d tree -r -1')
+ self.run_bzr('repair-workingtree -d tree -r -1')
tree = workingtree.WorkingTree.open('tree')
# At this point, check should be happy
tree.check_state()
=== modified file 'doc/en/release-notes/bzr-2.4.txt'
--- a/doc/en/release-notes/bzr-2.4.txt 2011-01-24 21:26:40 +0000
+++ b/doc/en/release-notes/bzr-2.4.txt 2011-01-27 16:27:05 +0000
@@ -29,7 +29,7 @@
.. Improvements to existing commands, especially improved performance
or memory usage, or better results.
-* A new hidden command ``bzr reset-workingtree``. This is a way to force
+* A new hidden command ``bzr repair-workingtree``. This is a way to force
the dirstate file to be rebuilt, rather than using a ``bzr checkout``
workaround. (John Arbash Meinel)
More information about the bazaar-commits
mailing list