code: def run(sub_command, quiet=False, no_edit=False, no_verify=False):
      
      if _working_dirs[0] != '.':
          git_command = 'git -C "%s"' % _working_dirs[0]
      else:
          git_command = 'git'
      edit = 'GIT_EDITOR=true' if no_edit else ''
      verify = 'GIT_SSL_NO_VERIFY=true' if no_verify else ''
      command = '%s %s %s %s' % (verify, edit, git_command, sub_command)
      if not quiet:
          logger.info('$ %s', command)
      status_, output = getstatusoutput(command)
      if status_:
          if quiet:
              logger.info('$ %s', command)
          logger.error('\n%s', output)
          if 'unknown revision' in output:
              raise UnknownRevision(command, status_, output)
          elif 'remote ref does not exist' in output:
              raise NoRemoteRef(command, status_, output)
          elif 'no such commit' in output:
              raise NoSuchCommit(command, status_, output)
          elif 'reference already exists' in output:
              raise ExistingReference(command, status_, output)
          elif re.search('Resolved|CONFLICT|Recorded preimage', output):
              raise ResolveError(command, status_, output)
          elif re.search('branch named.*already exists', output):
              raise ExistingBranch(command, status, output)
          raise GitError(command, status_, output)
      elif output and not quiet:
          logger.info('\n%s', output)
      return output
docs: Run a git command
  
      Prefix that sub_command with "git "
          then run the command in shell
  
      If quiet if True then do not log results
      If no_edit is True then prefix the git command with "GIT_EDITOR=true"
          (which does not wait on user's editor)
  
      If the command gives a non-zero status, raise a GitError exception