[Pkg-bazaar-commits] ./bzr/unstable r980: - bzr commit from subdirectory should commit the whole tree
Martin Pool
mbp at sourcefrog.net
Fri Apr 10 08:21:39 UTC 2009
------------------------------------------------------------
revno: 980
committer: Martin Pool <mbp at sourcefrog.net>
timestamp: Mon 2005-07-25 19:52:42 -0300
message:
- bzr commit from subdirectory should commit the whole tree
modified:
bzrlib/commands.py
bzrlib/selftest/versioning.py
-------------- next part --------------
=== modified file 'bzrlib/commands.py'
--- a/bzrlib/commands.py 2005-07-25 21:54:01 +0000
+++ b/bzrlib/commands.py 2005-07-25 22:52:42 +0000
@@ -1236,11 +1236,7 @@
b = find_branch('.')
if selected_list:
selected_list = [b.relpath(s) for s in selected_list]
- else:
- selected_list = [b.relpath('.')]
- if selected_list == ['.']:
- selected_list = None
-
+
try:
b.commit(message, verbose=verbose,
specific_files=selected_list,
=== modified file 'bzrlib/selftest/versioning.py'
--- a/bzrlib/selftest/versioning.py 2005-07-25 21:54:01 +0000
+++ b/bzrlib/selftest/versioning.py 2005-07-25 22:52:42 +0000
@@ -100,14 +100,14 @@
os.chdir('a')
# commit from here should do nothing
- run_bzr('commit', '.', '-m', 'commit subdir again', '--unchanged')
+ run_bzr('commit', '.', '-m', 'commit subdir only', '--unchanged')
v3 = b.revision_tree(b.lookup_revision(3))
eq(v3.get_file_by_path('b/two').read(), 'old contents')
eq(v3.get_file_by_path('top').read(), 'old contents')
eq(v3.get_file_by_path('a/one').read(), 'new contents')
# commit in subdirectory commits whole tree
- run_bzr('commit', '-m', 'commit in subdir')
+ run_bzr('commit', '-m', 'commit whole tree from subdir')
v4 = b.revision_tree(b.lookup_revision(4))
eq(v4.get_file_by_path('b/two').read(), 'new contents')
eq(v4.get_file_by_path('top').read(), 'new contents')
More information about the Pkg-bazaar-commits
mailing list