sh
  • Usage
    • Passing Arguments
      • Keyword Arguments
    • Exit Codes & Exceptions
      • Signals
    • Redirection
      • Filename
      • File-like Object
      • Function Callback
    • Asynchronous Execution
      • Incremental Iteration
      • Background Processes
        • Output Callbacks
        • Interactive callbacks
        • Done Callbacks
    • Baking
    • Piping
      • Basic
      • Advanced
    • Sub-commands
    • Default Arguments
    • Environments
    • Input via STDIN
    • ‘With’ Contexts
  • Reference
    • Special Kwargs
      • Controlling Output
        • _out
        • _err
        • _err_to_out
        • _encoding
        • _decode_errors
        • _tee
        • _truncate_exc
      • Execution
        • _fg
        • _bg
        • _bg_exc
        • _env
        • _timeout
        • _timeout_signal
        • _cwd
        • _ok_code
        • _new_session
        • _uid
        • _preexec_fn
        • _pass_fds
        • _close_fds
      • Communication
        • _in
        • _piped
        • _iter
        • _iter_noblock
        • _with
        • _done
      • TTYs
        • _tty_in
        • _tty_out
        • _unify_ttys
        • _tty_size
      • Performance & Optimization
        • _in_bufsize
        • _out_bufsize
        • _err_bufsize
        • _internal_bufsize
        • _no_out
        • _no_err
        • _no_pipe
      • Program Arguments
        • _long_sep
        • _long_prefix
        • _arg_preprocess
      • Misc
        • _log_msg
    • Architecture Overview
      • Launch
        • Child
        • Parent
      • Running
        • Buffers
      • Exit
        • STDIN Thread Shutdown
        • STDOUT/ERR Thread Shutdown
        • Exit Code Processing
        • Done Callback
    • API
      • Command Class
      • RunningCommand Class
      • OProc Class
      • Exceptions
        • ErrorReturnCode
        • SignalException
        • TimeoutException
        • CommandNotFound
      • Helper Functions
  • Contrib Commands
    • Commands
      • Sudo
      • Git
      • SSH
    • Extending
  • Using Sudo
    • sh.contrib.sudo
      • Terminal Input
      • String Input
    • /etc/sudoers NOPASSWD
    • sh.sudo
    • _fg=True
  • Tutorials
    • Tailing a real-time log file
    • Entering an SSH password
      • SSH Contrib command
      • How you should REALLY be using SSH
  • FAQ
    • How do I execute a bash builtin?
    • Will Windows be supported?
    • How do I append output to a file?
    • Why does my command’s output have color?
    • Why is _tty_out=True the default?
    • Why doesn’t “*” work as a command argument?
    • How do I call a program that isn’t in $PATH?
    • How do I execute a program with a dash in its name?
    • How do I execute a program with a special character in its name?
    • Why not use | to pipe commands?
    • Why isn’t piping asynchronous by default?
    • How do I run a command and connect it to sys.stdout and sys.stdin?
    • Why do my arguments need to be separate strings?
    • How do I order keyword arguments?
    • How to disable pylint E1101 no-member errors?
    • How do I patch sh in my tests?
    • Why is sh just a single file?
    • How do I see the commands sh is running?
sh
  • »
  • Index

Index

B | C | E | F | G | I | K | L | P | S | T | W

B

  • bake() (Command method)
  • built-in function
    • fn(), [1], [2], [3]
    • git()
    • pushd()
    • ssh()
    • sudo()
    • which()

C

  • chars (SessionContent attribute)
  • Command (built-in class)
  • ctty (OProc attribute)
    • (RunningCommand attribute)
  • cur_char (SessionContent attribute)
  • cur_line (SessionContent attribute)

E

  • ErrorReturnCode (built-in class)
  • exit_code (ErrorReturnCode attribute)
    • (OProc attribute)
    • (RunningCommand attribute)

F

  • fn()
    • built-in function, [1], [2], [3]
  • full_cmd (ErrorReturnCode attribute)

G

  • git()
    • built-in function

I

  • is_alive() (RunningCommand method)

K

  • kill() (OProc method)
    • (RunningCommand method)
  • kill_group() (OProc method)
    • (RunningCommand method)

L

  • last_line (SessionContent attribute)
  • line_chars (SessionContent attribute)
  • lines (SessionContent attribute)

P

  • pgid (OProc attribute)
    • (RunningCommand attribute)
  • pid (OProc attribute)
    • (RunningCommand attribute)
  • process (RunningCommand attribute)
  • pushd()
    • built-in function

S

  • SessionContent (built-in class)
  • sid (OProc attribute)
    • (RunningCommand attribute)
  • signal() (OProc method)
    • (RunningCommand method)
  • signal_group() (OProc method)
    • (RunningCommand method)
  • ssh()
    • built-in function
  • stderr (ErrorReturnCode attribute)
    • (OProc attribute)
    • (RunningCommand attribute)
  • stdout (ErrorReturnCode attribute)
    • (OProc attribute)
    • (RunningCommand attribute)
  • sudo()
    • built-in function

T

  • terminate() (OProc method)
    • (RunningCommand method)

W

  • wait() (OProc method)
    • (RunningCommand method)
  • which()
    • built-in function

© Copyright 2020, Andrew Moffat

Built with Sphinx using a theme provided by Read the Docs.