mercurial/commands.py
branchstable
changeset 19180 12dbdd348bb0
parent 19112 23f785b38af3
child 19184 05390cfe678a
child 19197 01d68fb07915
equal deleted inserted replaced
19169:bcdfb6078b9f 19180:12dbdd348bb0
   941     Use the command :hg:`update` to switch to an existing branch. Use
   941     Use the command :hg:`update` to switch to an existing branch. Use
   942     :hg:`commit --close-branch` to mark this branch as closed.
   942     :hg:`commit --close-branch` to mark this branch as closed.
   943 
   943 
   944     Returns 0 on success.
   944     Returns 0 on success.
   945     """
   945     """
       
   946     if label:
       
   947         label = label.strip()
       
   948 
   946     if not opts.get('clean') and not label:
   949     if not opts.get('clean') and not label:
   947         ui.write("%s\n" % repo.dirstate.branch())
   950         ui.write("%s\n" % repo.dirstate.branch())
   948         return
   951         return
   949 
   952 
   950     wlock = repo.wlock()
   953     wlock = repo.wlock()