parameters: ()
return_statement: return active, branches
docstring: Returns a tuple of active,branches.
  
    The 'active' is the name of the currently active branch and 'branches' is a
    list of all branches.
docstring_summary: Returns a tuple of active,branches.
docstring_tokens: Returns a tuple of active branches .
function: def _GetBranches():
    """Returns a tuple of active,branches.
  
    The 'active' is the name of the currently active branch and 'branches' is a
    list of all branches.
    """
    lines = _RunCommand(['git', 'branch'])[0].split('\n')
    branches = []
    active = ''
    for line in lines:
      if '*' in line:
        # The assumption is that the first char will always be the '*'.
        active = line[1:].strip()
        branches.append(active)
      else:
        branch = line.strip()
        if branch:
          branches.append(branch)
    return active, branches
function_tokens: def _GetBranches ( ) : lines = _RunCommand ( [ 'git' , 'branch' ] ) [ 0 ] . split ( '\n' ) branches = [ ] active = '' for line in lines : if '*' in line : # The assumption is that the first char will always be the '*'. active = line [ 1 : ] . strip ( ) branches . append ( active ) else : branch = line . strip ( ) if branch : branches . append ( branch ) return active , branches