mercurial/commands.py
changeset 15611 ec8a49c46d7e
parent 15585 a348739da8f0
parent 15610 09b200396384
child 15614 260a6449d83a
equal deleted inserted replaced
15606:2ad4e9b44d8b 15611:ec8a49c46d7e
   824     ('C', 'clean', None, _('reset branch name to parent branch name'))],
   824     ('C', 'clean', None, _('reset branch name to parent branch name'))],
   825     _('[-fC] [NAME]'))
   825     _('[-fC] [NAME]'))
   826 def branch(ui, repo, label=None, **opts):
   826 def branch(ui, repo, label=None, **opts):
   827     """set or show the current branch name
   827     """set or show the current branch name
   828 
   828 
       
   829     .. note::
       
   830        Branch names are permanent and global. Use :hg:`bookmark` to create a
       
   831        light-weight bookmark instead. See :hg:`help glossary` for more
       
   832        information about named branches and bookmarks.
       
   833 
   829     With no argument, show the current branch name. With one argument,
   834     With no argument, show the current branch name. With one argument,
   830     set the working directory branch name (the branch will not exist
   835     set the working directory branch name (the branch will not exist
   831     in the repository until the next commit). Standard practice
   836     in the repository until the next commit). Standard practice
   832     recommends that primary development take place on the 'default'
   837     recommends that primary development take place on the 'default'
   833     branch.
   838     branch.
   839     the parent of the working directory, negating a previous branch
   844     the parent of the working directory, negating a previous branch
   840     change.
   845     change.
   841 
   846 
   842     Use the command :hg:`update` to switch to an existing branch. Use
   847     Use the command :hg:`update` to switch to an existing branch. Use
   843     :hg:`commit --close-branch` to mark this branch as closed.
   848     :hg:`commit --close-branch` to mark this branch as closed.
   844 
       
   845     .. note::
       
   846        Branch names are permanent. Use :hg:`bookmark` to create a
       
   847        light-weight bookmark instead. See :hg:`help glossary` for more
       
   848        information about named branches and bookmarks.
       
   849 
   849 
   850     Returns 0 on success.
   850     Returns 0 on success.
   851     """
   851     """
   852 
   852 
   853     if opts.get('clean'):
   853     if opts.get('clean'):