~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/delta.py

  • Committer: John Arbash Meinel
  • Date: 2006-08-14 16:16:53 UTC
  • mto: (1946.2.6 reduce-knit-churn)
  • mto: This revision was merged to the branch mainline in revision 1919.
  • Revision ID: john@arbash-meinel.com-20060814161653-54cdcdadcd4e9003
Remove bogus entry from BRANCH.TODO

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
# Copyright (C) 2005, 2006 Canonical Ltd
 
1
# Copyright (C) 2005, 2006 Canonical
2
2
#
3
3
# This program is free software; you can redistribute it and/or modify
4
4
# it under the terms of the GNU General Public License as published by
152
152
        want_unchanged=want_unchanged,
153
153
        specific_files=specific_files,
154
154
        extra_trees=extra_trees,
155
 
        require_versioned=require_versioned,
156
 
        include_root=False)
157
 
 
158
 
 
159
 
def _compare_trees(old_tree, new_tree, want_unchanged, specific_file_ids,
160
 
                   include_root):
 
155
        require_versioned=require_versioned)
 
156
 
 
157
 
 
158
def _compare_trees(old_tree, new_tree, want_unchanged, specific_file_ids):
161
159
 
162
160
    from osutils import is_inside_any
 
161
    
163
162
    old_inv = old_tree.inventory
164
163
    new_inv = new_tree.inventory
165
164
    delta = TreeDelta()
166
 
    # mutter('start compare_trees')
 
165
    mutter('start compare_trees')
167
166
 
168
167
    # TODO: Rather than iterating over the whole tree and then filtering, we
169
168
    # could diff just the specified files (if any) and their subtrees.  
170
169
 
171
 
    old_files = old_tree.list_files(include_root)
172
 
    new_files = new_tree.list_files(include_root)
 
170
    old_files = old_tree.list_files()
 
171
    new_files = new_tree.list_files()
173
172
 
174
173
    more_old = True
175
174
    more_new = True
252
251
            assert entry.file_id not in added
253
252
            added[entry.file_id] = path, entry
254
253
 
255
 
    while old_path is not None or new_path is not None:
 
254
    while old_path or new_path:
256
255
        # list_files() returns files in alphabetical path sorted order
257
256
        if old_path == new_path:
258
257
            if old_file_id == new_file_id: