Socket
Socket
Sign inDemoInstall

node-pty

Package Overview
Dependencies
Maintainers
3
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.8.2-beta1 to 0.9.0-beta1

scripts/publish.js

0

deps/winpty/misc/EnableExtendedFlags.txt

@@ -0,0 +0,0 @@ Note regarding ENABLE_EXTENDED_FLAGS (2016-05-30)

@@ -0,0 +0,0 @@ ==================================================================

@@ -0,0 +0,0 @@ ==================================

@@ -0,0 +0,0 @@ ==================================

@@ -0,0 +0,0 @@ =======================================

@@ -0,0 +0,0 @@ ==========================================================

@@ -0,0 +0,0 @@ =====================================

@@ -0,0 +0,0 @@ ===========================================================

@@ -0,0 +0,0 @@ The narrowest allowed console window, in pixels, on a conventional (~96dpi)

@@ -0,0 +0,0 @@ As before, avoid odd sizes in favor of even sizes.

@@ -0,0 +0,0 @@ Introduction

@@ -0,0 +0,0 @@ Test programs

@@ -0,0 +0,0 @@ # winpty

@@ -0,0 +0,0 @@ # Version 0.4.3 (2017-05-17)

@@ -0,0 +0,0 @@ "use strict";

@@ -0,0 +0,0 @@ "use strict";

@@ -0,0 +0,0 @@ "use strict";

@@ -0,0 +0,0 @@ "use strict";

@@ -0,0 +0,0 @@ "use strict";

@@ -47,2 +47,12 @@ "use strict";

});
Object.defineProperty(Terminal.prototype, "cols", {
get: function () { return this._cols; },
enumerable: true,
configurable: true
});
Object.defineProperty(Terminal.prototype, "rows", {
get: function () { return this._rows; },
enumerable: true,
configurable: true
});
Terminal.prototype._forwardEvents = function () {

@@ -49,0 +59,0 @@ var _this = this;

@@ -0,0 +0,0 @@ "use strict";

@@ -0,0 +0,0 @@ "use strict";

27

lib/unixTerminal.js
"use strict";
/**
* Copyright (c) 2012-2015, Christopher Jeffrey (MIT License)
* Copyright (c) 2016, Daniel Imms (MIT License).
* Copyright (c) 2018, Microsoft Corporation (MIT License).
*/
var __extends = (this && this.__extends) || (function () {

@@ -21,2 +16,7 @@ var extendStatics = function (d, b) {

Object.defineProperty(exports, "__esModule", { value: true });
/**
* Copyright (c) 2012-2015, Christopher Jeffrey (MIT License)
* Copyright (c) 2016, Daniel Imms (MIT License).
* Copyright (c) 2018, Microsoft Corporation (MIT License).
*/
var net = require("net");

@@ -47,4 +47,4 @@ var terminal_1 = require("./terminal");

opt.env = opt.env || process.env;
var cols = opt.cols || terminal_1.DEFAULT_COLS;
var rows = opt.rows || terminal_1.DEFAULT_ROWS;
_this._cols = opt.cols || terminal_1.DEFAULT_COLS;
_this._rows = opt.rows || terminal_1.DEFAULT_ROWS;
var uid = opt.uid || -1;

@@ -88,3 +88,3 @@ var gid = opt.gid || -1;

// fork
var term = pty.fork(file, args, parsedEnv, cwd, cols, rows, uid, gid, (encoding === 'utf8'), onexit);
var term = pty.fork(file, args, parsedEnv, cwd, _this._cols, _this._rows, uid, gid, (encoding === 'utf8'), onexit);
_this._socket = new PipeSocket(term.fd);

@@ -227,2 +227,4 @@ if (encoding !== null) {

pty.resize(this._fd, cols, rows);
this._cols = cols;
this._rows = rows;
};

@@ -255,8 +257,7 @@ UnixTerminal.prototype._sanitizeEnv = function (env) {

var _this = this;
var tty = process.binding('tty_wrap');
var guessHandleType = tty.guessHandleType;
tty.guessHandleType = function () { return 'PIPE'; };
var _a = process.binding('pipe_wrap'), Pipe = _a.Pipe, constants = _a.constants; // tslint:disable-line
// @types/node has fd as string? https://github.com/DefinitelyTyped/DefinitelyTyped/pull/18275
_this = _super.call(this, { fd: fd }) || this;
tty.guessHandleType = guessHandleType;
var handle = new Pipe(constants.SOCKET);
handle.open(fd);
_this = _super.call(this, { handle: handle }) || this;
return _this;

@@ -263,0 +264,0 @@ }

@@ -0,0 +0,0 @@ "use strict";

@@ -0,0 +0,0 @@ "use strict";

@@ -85,3 +85,3 @@ "use strict";

if (this._useConpty) {
var connect = this._ptyNative.connect(this._pty, commandLine, cwd, env, this._$onProcessExit.bind(this));
var connect = this._ptyNative.connect(this._pty, commandLine, cwd, env, function (c) { return _this._$onProcessExit(c); });
this._innerPid = connect.pid;

@@ -88,0 +88,0 @@ }

@@ -0,0 +0,0 @@ "use strict";

@@ -39,4 +39,4 @@ "use strict";

var env = utils_1.assign({}, opt.env);
var cols = opt.cols || terminal_1.DEFAULT_COLS;
var rows = opt.rows || terminal_1.DEFAULT_ROWS;
_this._cols = opt.cols || terminal_1.DEFAULT_COLS;
_this._rows = opt.rows || terminal_1.DEFAULT_ROWS;
var cwd = opt.cwd || process.cwd();

@@ -50,3 +50,3 @@ var name = opt.name || env.TERM || DEFAULT_NAME;

// Create new termal.
_this._agent = new windowsPtyAgent_1.WindowsPtyAgent(file, args, parsedEnv, cwd, cols, rows, false, opt.experimentalUseConpty);
_this._agent = new windowsPtyAgent_1.WindowsPtyAgent(file, args, parsedEnv, cwd, _this._cols, _this._rows, false, opt.experimentalUseConpty);
_this._socket = _this._agent.outSocket;

@@ -136,2 +136,4 @@ // Not available until `ready` event emitted.

_this._agent.resize(cols, rows);
_this._cols = cols;
_this._rows = rows;
});

@@ -138,0 +140,0 @@ };

@@ -0,0 +0,0 @@ "use strict";

@@ -7,3 +7,3 @@ {

},
"version": "0.8.2-beta1",
"version": "0.9.0-beta1",
"license": "MIT",

@@ -46,3 +46,3 @@ "main": "./lib/index.js",

"dependencies": {
"nan": "2.12.1"
"nan": "^2.13.2"
},

@@ -60,2 +60,2 @@ "devDependencies": {

}
}
}
# node-pty
[![Build Status](https://dev.azure.com/vscode/node-pty/_apis/build/status/Microsoft.node-pty)](https://dev.azure.com/vscode/node-pty/_apis/build/status/Microsoft.node-pty?branchName=master)
[![Build Status](https://dev.azure.com/vscode/node-pty/_apis/build/status/Microsoft.node-pty)](https://dev.azure.com/vscode/node-pty/_build/latest?definitionId=11)

@@ -5,0 +5,0 @@ `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.

@@ -0,0 +0,0 @@ 'use strict'

@@ -0,0 +0,0 @@ var fs = require('fs');

@@ -0,0 +0,0 @@ /**

@@ -0,0 +0,0 @@ /**

@@ -0,0 +0,0 @@ /**

@@ -0,0 +0,0 @@ /**

@@ -0,0 +0,0 @@ /**

@@ -0,0 +0,0 @@ /**

@@ -38,2 +38,4 @@ /**

public get pid(): number { return this._pid; }
public get cols(): number { return this._cols; }
public get rows(): number { return this._rows; }

@@ -40,0 +42,0 @@ constructor(opt?: IPtyForkOptions) {

@@ -0,0 +0,0 @@ /**

@@ -0,0 +0,0 @@ /**

@@ -6,3 +6,2 @@ /**

*/
import * as net from 'net';

@@ -56,4 +55,4 @@ import { Terminal, DEFAULT_COLS, DEFAULT_ROWS } from './terminal';

const cols = opt.cols || DEFAULT_COLS;
const rows = opt.rows || DEFAULT_ROWS;
this._cols = opt.cols || DEFAULT_COLS;
this._rows = opt.rows || DEFAULT_ROWS;
const uid = opt.uid || -1;

@@ -102,3 +101,3 @@ const gid = opt.gid || -1;

// fork
const term = pty.fork(file, args, parsedEnv, cwd, cols, rows, uid, gid, (encoding === 'utf8'), onexit);
const term = pty.fork(file, args, parsedEnv, cwd, this._cols, this._rows, uid, gid, (encoding === 'utf8'), onexit);

@@ -255,2 +254,4 @@ this._socket = new PipeSocket(term.fd);

pty.resize(this._fd, cols, rows);
this._cols = cols;
this._rows = rows;
}

@@ -283,9 +284,8 @@

constructor(fd: number) {
const tty = (<any>process).binding('tty_wrap');
const guessHandleType = tty.guessHandleType;
tty.guessHandleType = () => 'PIPE';
const { Pipe, constants } = (<any>process).binding('pipe_wrap'); // tslint:disable-line
// @types/node has fd as string? https://github.com/DefinitelyTyped/DefinitelyTyped/pull/18275
super({ fd: <any>fd });
tty.guessHandleType = guessHandleType;
const handle = new Pipe(constants.SOCKET);
handle.open(fd);
super(<any>{ handle });
}
}

@@ -0,0 +0,0 @@ /**

@@ -0,0 +0,0 @@ /**

@@ -118,3 +118,4 @@ /**

if (this._useConpty) {
const connect = (this._ptyNative as IConptyNative).connect(this._pty, commandLine, cwd, env, this._$onProcessExit.bind(this));
const connect = (this._ptyNative as IConptyNative).connect(this._pty, commandLine, cwd, env, c => this._$onProcessExit(c)
);
this._innerPid = connect.pid;

@@ -121,0 +122,0 @@ }

@@ -0,0 +0,0 @@ /**

@@ -36,4 +36,4 @@ /**

const env = assign({}, opt.env);
const cols = opt.cols || DEFAULT_COLS;
const rows = opt.rows || DEFAULT_ROWS;
this._cols = opt.cols || DEFAULT_COLS;
this._rows = opt.rows || DEFAULT_ROWS;
const cwd = opt.cwd || process.cwd();

@@ -50,3 +50,3 @@ const name = opt.name || env.TERM || DEFAULT_NAME;

// Create new termal.
this._agent = new WindowsPtyAgent(file, args, parsedEnv, cwd, cols, rows, false, opt.experimentalUseConpty);
this._agent = new WindowsPtyAgent(file, args, parsedEnv, cwd, this._cols, this._rows, false, opt.experimentalUseConpty);
this._socket = this._agent.outSocket;

@@ -154,2 +154,4 @@

this._agent.resize(cols, rows);
this._cols = cols;
this._rows = rows;
});

@@ -156,0 +158,0 @@ }

@@ -49,2 +49,12 @@ /**

/**
* The column size in characters.
*/
cols: number;
/**
* The row size in characters.
*/
rows: number;
/**
* The title of the active process.

@@ -51,0 +61,0 @@ */

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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