Git Product home page Git Product logo

ppty's Introduction

ppty -- run process in pseudoterminal.

Python implementation of pty. ( Chapter 19 of APUE by W. Richard Stevens.)

Test in Python 3.6 and 2.7 in `4.12.8-2-ARCH GNU/Linux

Install

pip install ppty

Usage

usage: ppty [-h] [-i] [-e] [-n] [-d DRIVER] [-v] prog [args [args ...]]

Run process in pseudoterminal

positional arguments:
  prog                  program to run
  args                  args to the program

optional arguments:
  -h, --help            show this help message and exit
  -i, --ignoreeof       ignore EOF on stdin
  -e, --noecho          noecho for slave pty
  -n, --no-interactive  not interactive
  -d DRIVER, --driver DRIVER
                        driver (executable) for stdin/stdout
  -v, --verbose

Example

ppty sh
ppty -i slowout </dev/null >file.out &  # monitor a slow output and long-running program in the background
ppty sh | tee typescript  # simulate scirpt(1)

ppty's People

Contributors

qingyunha avatar

Watchers

Makefile君 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.