Socket
Socket
Sign inDemoInstall

node-pty

Package Overview
Dependencies
Maintainers
1
Versions
164
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

node-pty - npm Package Compare versions

Comparing version 0.5.0 to 0.5.1

.npmignore

18

package.json

@@ -7,5 +7,5 @@ {

},
"version": "0.5.0",
"version": "0.5.1",
"license": "MIT",
"main": "./lib/index.js",
"main": "./index.js",
"repository": {

@@ -15,5 +15,2 @@ "type": "git",

},
"files": [
"lib/"
],
"homepage": "https://github.com/Tyriar/node-pty",

@@ -29,7 +26,6 @@ "bugs": {

"scripts": {
"tsc": "tsc",
"tslint": "tslint src/**/*.ts",
"install": "node scripts/install.js",
"postinstall": "node scripts/post-install.js",
"test": "cross-env NODE_ENV=test mocha -R spec test"
"test": "NODE_ENV=test mocha -R spec",
"test-windows": "set \"NODE_ENV=test\" && mocha -R spec test-windows"
},

@@ -46,8 +42,4 @@ "tags": [

"devDependencies": {
"@types/node": "^6.0.58",
"cross-env": "^3.1.3",
"mocha": "^3.1.2",
"tslint": "^4.3.1",
"typescript": "^2.1.4"
"mocha": "~1.17.1"
}
}
# node-pty
**⚠️ This project is currently under development to improve Windows support, see [this issue](https://github.com/Microsoft/vscode/issues/13625) for more details.**
`forkpty(3)` bindings for node.js. This allows you to fork processes with pseudo

@@ -16,8 +18,5 @@ terminal file descriptors. It returns a terminal object which allows reads

``` js
var os = require('os');
var pty = require('node-pty');
var shell = os.platform() === 'win32' ? 'powershell.exe' : 'bash';
var ptyProcess = pty.spawn(shell, [], {
var term = pty.spawn('bash', [], {
name: 'xterm-color',

@@ -30,27 +29,16 @@ cols: 80,

ptyProcess.on('data', function(data) {
term.on('data', function(data) {
console.log(data);
});
ptyProcess.write('ls\r');
ptyProcess.resize(100, 40);
ptyProcess.write('ls\r');
term.write('ls\r');
term.resize(100, 40);
term.write('ls /\r');
console.log(term.process);
```
## Troubleshooting
**Powershell gives error 8009001d**
>
Internal Windows PowerShell error. Loading managed Windows PowerShell failed with error 8009001d.
This happens when PowerShell is launched with no `SystemRoot` environment variable present.
## pty.js
This 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.
## License
Copyright (c) 2012-2015, Christopher Jeffrey (MIT License).<br>
Copyright (c) 2012-2015, Christopher Jeffrey (MIT License).
Copyright (c) 2016, Daniel Imms (MIT License).

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc