parameters: (cmd, buffer_output=False, discard_stdout=False, discard_stderr=False)
docstring: Starts the given command and returns a handler to it.
  
          :param list cmd: Command to be run as a list of arguments (strings).
          :param bool buffer_output: See above.
  
          :returns: A handler to the started command (``subprocess.Popen``).
  
          If the output is irrelevant for you, you should set `buffer_output` to
          ``True`` and ignore the `output`.
docstring_summary: Starts the given command and returns a handler to it.
docstring_tokens: Starts the given command and returns a handler to it .
function: def _start(cmd, buffer_output=False, discard_stdout=False, discard_stderr=False):
          """Starts the given command and returns a handler to it.
  
          :param list cmd: Command to be run as a list of arguments (strings).
          :param bool buffer_output: See above.
  
          :returns: A handler to the started command (``subprocess.Popen``).
  
          If the output is irrelevant for you, you should set `buffer_output` to
          ``True`` and ignore the `output`.
          """
          # The implementation is platform-specific because we want to be able to
          # kill the children alongside with the process.
  
          if discard_stdout:
              stdout = subprocess.DEVNULL
          elif buffer_output:
              stdout = subprocess.PIPE
          else:
              stdout = None
  
          if discard_stderr:
              stderr = subprocess.DEVNULL
          elif buffer_output:
              if discard_stdout:
                  stderr = subprocess.PIPE
              else:
                  stderr = subprocess.STDOUT
          else:
              stderr = None
  
          kwargs = dict(
              args=cmd,
              stdin=subprocess.PIPE,
              stdout=stdout,
              stderr=stderr,
              universal_newlines=True
          )
          if is_windows():
              return _WindowsProcess(**kwargs)
          else:
              return _LinuxProcess(**kwargs)
function_tokens: def _start ( cmd , buffer_output = False , discard_stdout = False , discard_stderr = False ) : # The implementation is platform-specific because we want to be able to # kill the children alongside with the process. if discard_stdout : stdout = subprocess . DEVNULL elif buffer_output : stdout = subprocess . PIPE else : stdout = None if discard_stderr : stderr = subprocess . DEVNULL elif buffer_output : if discard_stdout : stderr = subprocess . PIPE else : stderr = subprocess . STDOUT else : stderr = None kwargs = dict ( args = cmd , stdin = subprocess . PIPE , stdout = stdout , stderr = stderr , universal_newlines = True ) if is_windows ( ) : return _WindowsProcess ( * * kwargs ) else : return _LinuxProcess ( * * kwargs )