/brz/remove-bazaar

To get this branch, use:
bzr branch http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar

« back to all changes in this revision

Viewing changes to bzrlib/commit.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2007-09-05 02:36:00 UTC
  • mfrom: (2747.6.13 52479)
  • Revision ID: pqm@pqm.ubuntu.com-20070905023600-6h6s51el362b171a
The location being committed to is displayed.  (Daniel Watkins, #52479)

Show diffs side-by-side

added added

removed removed

Lines of Context:
80
80
        deprecated_function,
81
81
        DEPRECATED_PARAMETER)
82
82
from bzrlib.workingtree import WorkingTree
 
83
from bzrlib.urlutils import unescape_for_display
83
84
import bzrlib.ui
84
85
 
85
86
 
86
87
class NullCommitReporter(object):
87
88
    """I report on progress of a commit."""
88
89
 
 
90
    def started(self, revno, revid, location=None):
 
91
        pass
 
92
 
89
93
    def snapshot_change(self, change, path):
90
94
        pass
91
95
 
121
125
            return
122
126
        self._note("%s %s", change, path)
123
127
 
 
128
    def started(self, revno, rev_id, location=None):
 
129
        if location is not None:
 
130
            location = ' to "' + unescape_for_display(location, 'utf-8') + '"'
 
131
        else:
 
132
            location = ''
 
133
        self._note('Committing revision %d%s.', revno, location)
 
134
 
124
135
    def completed(self, revno, rev_id):
125
136
        self._note('Committed revision %d.', revno)
126
137
    
290
301
            self._gather_parents()
291
302
            if len(self.parents) > 1 and self.specific_files:
292
303
                raise errors.CannotCommitSelectedFileMerge(self.specific_files)
293
 
            
 
304
 
294
305
            # Collect the changes
295
306
            self._set_progress_stage("Collecting changes",
296
307
                    entries_title="Directory")
298
309
                self.config, timestamp, timezone, committer, revprops, rev_id)
299
310
            
300
311
            try:
 
312
                # find the location being committed to
 
313
                if self.bound_branch:
 
314
                    master_location = self.master_branch.base
 
315
                else:
 
316
                    master_location = self.branch.base
 
317
 
 
318
                # report the start of the commit
 
319
                self.reporter.started(new_revno, self.rev_id, master_location)
 
320
 
301
321
                self._update_builder_with_changes()
302
322
                self._check_pointless()
303
323