{"name":"node-pty","description":"Fork pseudoterminals in Node.JS","author":{"name":"Daniel Imms"},"version":"0.7.4-node-10","license":"MIT","main":"./lib/index.js","types":"./typings/node-pty.d.ts","repository":{"type":"git","url":"git://github.com/Tyriar/node-pty.git"},"files":["binding.gyp","lib/","scripts/","src/","deps/"],"homepage":"https://github.com/Tyriar/node-pty","bugs":{"url":"https://github.com/Tyriar/node-pty/issues"},"keywords":["pty","tty","terminal","pseudoterminal","forkpty","openpty"],"scripts":{"tsc":"tsc","lint":"tslint 'src/**/*.ts'","install":"node scripts/install.js","postinstall":"node scripts/post-install.js","test":"cross-env NODE_ENV=test mocha -R spec --exit lib/*.test.js","prepublish":"npm run tsc"},"dependencies":{"nan":"2.10.0"},"devDependencies":{"@types/mocha":"^5.0.0","@types/node":"^6.0.104","cross-env":"^5.1.4","mocha":"^5.0.5","pollUntil":"^1.0.3","tslint":"^5.9.1","tslint-consistent-codestyle":"^1.13.0","typescript":"^2.8.1"},"readme":"# node-pty\n\n[![Build status](https://tyriar.visualstudio.com/_apis/public/build/definitions/2d361770-e039-4acc-b2b2-ef8396473589/1/badge)](https://tyriar.visualstudio.com/node-pty/_build/index?definitionId=1)\n\n`forkpty(3)` bindings for node.js. This allows you to fork processes with pseudoterminal file descriptors. It returns a terminal object which allows reads and writes.\n\nThis is useful for:\n\n- Writing a terminal emulator (eg. via [xterm.js](https://github.com/sourcelair/xterm.js)).\n- Getting certain programs to *think* you're a terminal, such as when you need a program to send you control sequences.\n\n`node-pty` supports Linux, macOS and Windows. Windows support is possible by utilizing the [winpty](https://github.com/rprichard/winpty) library.\n\n## Real-world Uses\n\n`node-pty` powers many different terminal emulators, including:\n\n- [Microsoft Visual Studio Code](https://code.visualstudio.com)\n- [Hyper](https://hyper.is/)\n- [Upterm](https://github.com/railsware/upterm)\n- [Script Runner](https://github.com/ioquatix/script-runner) for Atom.\n- [Theia](https://github.com/theia-ide/theia)\n- [FreeMAN](https://github.com/matthew-matvei/freeman) file manager\n- [atom-xterm](https://atom.io/packages/atom-xterm) - Atom plugin for providing terminals inside your Atom workspace.\n\nDo you use node-pty in your application as well? Please open a [Pull Request](https://github.com/Tyriar/node-pty/pulls) to include it here. We would love to have it in our list.\n\n## Example Usage\n\n```js\nvar os = require('os');\nvar pty = require('node-pty');\n\nvar shell = os.platform() === 'win32' ? 'powershell.exe' : 'bash';\n\nvar ptyProcess = pty.spawn(shell, [], {\n  name: 'xterm-color',\n  cols: 80,\n  rows: 30,\n  cwd: process.env.HOME,\n  env: process.env\n});\n\nptyProcess.on('data', function(data) {\n  console.log(data);\n});\n\nptyProcess.write('ls\\r');\nptyProcess.resize(100, 40);\nptyProcess.write('ls\\r');\n```\n\n## Building\n\n```bash\n# Install dependencies and build C++\nnpm install\n# Compile TypeScript -> JavaScript\nnpm run tsc\n```\n\n### Dependencies on Windows\n\n`npm install` requires some tools to be present in the system like Python and C++ compiler. Windows users can easily install them by running the following command in PowerShell as administrator. For more information see https://github.com/felixrieseberg/windows-build-tools:\n\n```sh\nnpm install --global --production windows-build-tools\n```\n\n## Debugging\n\nOn Windows, you can show the winpty agent console window by adding the environment variable `WINPTY_SHOW_CONSOLE=1` to the pty's environment. See https://github.com/rprichard/winpty#debugging-winpty for more information.\n\n## Troubleshooting\n\n**Powershell gives error 8009001d**\n\n> Internal Windows PowerShell error.  Loading managed Windows PowerShell failed with error 8009001d.\n\nThis happens when PowerShell is launched with no `SystemRoot` environment variable present.\n\n## pty.js\n\nThis project is forked from [chjj/pty.js](https://github.com/chjj/pty.js) with the primary goals being to provide better support for later Node.JS versions and Windows.\n\n## License\n\nCopyright (c) 2012-2015, Christopher Jeffrey (MIT License).\nCopyright (c) 2016, Daniel Imms (MIT License).\n","readmeFilename":"README.md","gitHead":"7387d9983f7fe4ffa5866c3f9837ae6b6ea6eda5","_id":"node-pty@0.7.4-node-10","_npmVersion":"5.6.0","_nodeVersion":"8.9.3","_npmUser":{"name":"tyriar","email":"tyriar@tyriar.com"},"dist":{"integrity":"sha512-kUtNy5EBUgw0fm6/xzroyi3t0vTtRe1NvNku/issknWUlVei5EHBC0LHO4rj+YXK5rUJ3Npp5XfSJZjXUvPWOg==","shasum":"162e5646496eb582459a442b55689ac9f3564180","tarball":"http://registry-npm.ywwl.com/node-pty/download/node-pty-0.7.4-node-10.tgz","fileCount":226,"unpackedSize":991154,"npm-signature":"-----BEGIN PGP SIGNATURE-----\r\nVersion: OpenPGP.js v3.0.4\r\nComment: https://openpgpjs.org\r\n\r\nwsFcBAEBCAAQBQJbK+jGCRA9TVsSAnZWagAAUNEP/Awdgs2G9GkVCeYqHQaP\n5KFjtLXaX+YEVHYSr9jL7e8lW8cy99roqofxnA4SzJjP2bjunDLuiduBuM/M\nR1LlVljNSAnrnH72w/T7DUEaxPDh0Fkl7yHZBHNTgoIGvqiN6yEGuR6W7fTc\nsTxy1WDMKkP/RjTT9NZ0XPanu6ZqWd94csk0l41qcMSFgiXzbOOBUQjNUMf8\no0Wt9R+mz//MGQziFoys9jggKU7cFTmGVR3eV9SjSFIpuy1lXqfWko7GeWYu\nsGlZrdF44gHEqYx8Nbqo3iNylxQuywb3JIGA741zEA9M+D1K1TQUpC4Drey0\ntmRohmQW4XwM8odrYgLL8xlP8CS1sG1VqdAe9AYCMqmuzLQVIdYo+PrGgze6\no0K8g4ofa6c9VyLD/oooPivOWcXNssCzSWkNMbt7tkxRxFAtbpvwneaEtMmC\nwfyvcWK8dhdqBQXVi7I9NaJSbCX/NodsWju6YATMRFjWSg+ufk7ivwa+Zzm3\norjbEqKKneXa/MzEUPYuScHIpc5VFhSvYfMyzvbgj8L8OiwRZ146tgR9d84K\nUen4+gKastLcd27WBJTfM0M33C1gvwqKyKwkNWSWcaFqXAbg84ZXtCO/Uunx\nx71xv8y3rbCRGNV7wMJilQOPcmESxGSGT/P2iogHqBZOB6RZHDwtdkDduDSS\ndlwJ\r\n=+ZOC\r\n-----END PGP SIGNATURE-----\r\n","signatures":[{"keyid":"SHA256:jl3bwswu80PjjokCgh0o2w5c2U4LhQAE57gj9cz1kzA","sig":"MEUCICfXQYkS2r2s2FqWNkmEA+kOXzMXsClQQsIzxF+qSvkqAiEApapZWJcHBZ4PE0HmKq7maBGlxh6lNRl8r359ItavOfk="}],"size":216485,"noattachment":false,"key":"/node-pty/-/node-pty-0.7.4-node-10.tgz"},"maintainers":[{"name":"tyriar","email":"tyriar@tyriar.com"}],"directories":{},"_npmOperationalInternal":{"host":"s3://npm-registry-packages","tmp":"tmp/node-pty_0.7.4-node-10_1529604294230_0.6403149275400517"},"_hasShrinkwrap":false,"publish_time":1529604294458,"_cnpm_publish_time":1529604294458,"dist-tags":{"alpha":"0.10.0-alpha1","beta":"1.2.0-beta.18","conpty":"0.7.8-conpty1","latest":"1.1.0"}}