~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to bzrlib/builtins.py

  • Committer: Canonical.com Patch Queue Manager
  • Date: 2006-08-01 13:17:06 UTC
  • mfrom: (1711.2.109 jam-integration)
  • Revision ID: pqm@pqm.ubuntu.com-20060801131706-e6e4daaef24c3da3
(dato, jam) Updated user messages

Show diffs side-by-side

added added

removed removed

Lines of Context:
814
814
    def run(self, dir='.'):
815
815
        tree = WorkingTree.open_containing(dir)[0]
816
816
        tree.lock_write()
 
817
        existing_pending_merges = tree.pending_merges()
817
818
        try:
818
819
            last_rev = tree.last_revision() 
819
820
            if last_rev == tree.branch.last_revision():
826
827
            conflicts = tree.update()
827
828
            revno = tree.branch.revision_id_to_revno(tree.last_revision())
828
829
            note('Updated to revision %d.' % (revno,))
 
830
            if tree.pending_merges() != existing_pending_merges:
 
831
                note('Your local commits will now show as pending merges with '
 
832
                     "'bzr status', and can be committed with 'bzr commit'.")
829
833
            if conflicts != 0:
830
834
                return 1
831
835
            else:
1755
1759
            raise BzrCommandError("Commit refused because there are unknown "
1756
1760
                                  "files in the working tree.")
1757
1761
        except errors.BoundBranchOutOfDate, e:
1758
 
            raise BzrCommandError(str(e)
1759
 
                                  + ' Either unbind, update, or'
1760
 
                                    ' pass --local to commit.')
1761
 
 
 
1762
            raise BzrCommandError(str(e) + "\n"
 
1763
                'To commit to master branch, run update and then commit.\n'
 
1764
                'You can also pass --local to commit to continue working '
 
1765
                'disconnected.')
1762
1766
 
1763
1767
class cmd_check(Command):
1764
1768
    """Validate consistency of branch history.