~abentley/bzrtools/bzrtools.dev

« back to all changes in this revision

Viewing changes to bzrtools.py

  • Committer: Aaron Bentley
  • Date: 2005-11-11 17:43:12 UTC
  • Revision ID: aaron.bentley@utoronto.ca-20051111174312-1c627d82a07bf8fd
Added patch for tab-in-patch-filename support

Show diffs side-by-side

added added

removed removed

Lines of Context:
42
42
    >>> fooname = os.path.join(br.base, "foo")
43
43
    >>> file(fooname, "wb").write("bar")
44
44
    >>> is_clean(br)
45
 
    (True, ['foo'])
 
45
    (True, [u'foo'])
46
46
    >>> bzrlib.add.smart_add_branch(br, [br.base])
47
47
    1
48
48
    >>> is_clean(br)
60
60
        if file_class in ('?', 'I'):
61
61
            non_source.append(path)
62
62
    delta = compare_trees(old_tree, new_tree, want_unchanged=False)
63
 
    if len(delta.added) > 0 or len(delta.removed) > 0 or \
64
 
        len(delta.modified) > 0:
65
 
        return False, non_source
66
 
    return True, non_source 
 
63
    return not delta.has_changed(), non_source
67
64
 
68
65
def set_pull_data(br, location, rev_id):
69
66
    pull_file = file (br.controlfilename("x-pull-data"), "wb")
258
255
        push_location = location
259
256
    
260
257
    if push_location is None:
261
 
        print "No push location saved.  Please specify one on the command line."
262
 
        sys.exit(1)
 
258
        raise bzrlib.errors.MustUseDecorated
 
259
 
 
260
    if push_location.find('://') != -1:
 
261
        raise bzrlib.errors.MustUseDecorated
 
262
 
 
263
    if push_location.find(':') == -1:
 
264
        raise bzrlib.errors.MustUseDecorated
263
265
 
264
266
    clean, non_source = is_clean(cur_branch)
265
267
    if not clean: