diff --git a/README.md b/README.md index ecc18db5..77ba32a8 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,10 @@ A curses-like library with a high level terminal interface API for node.js. -![blessed](https://raw.githubusercontent.com/chjj/blessed/master/img/v0.1.0-3.gif) +Forked from the original [blessed](https://github.com/chjj/blessed) to make it +work with `node-pty` instead of `pty.js`. + +![blessed](https://raw.githubusercontent.com/danikaze/blessed/master/img/v0.1.0-3.gif) Blessed is over 16,000 lines of code and terminal goodness. It's completely implemented in javascript, and its goal consists of two things: diff --git a/lib/widgets/terminal.js b/lib/widgets/terminal.js index 3ed1bbec..f17406e3 100644 --- a/lib/widgets/terminal.js +++ b/lib/widgets/terminal.js @@ -215,7 +215,7 @@ Terminal.prototype.bootstrap = function() { return; } - this.pty = require('pty.js').fork(this.shell, this.args, { + this.pty = require('node-pty').fork(this.shell, this.args, { name: this.termName, cols: this.width - this.iwidth, rows: this.height - this.iheight, diff --git a/package-lock.json b/package-lock.json new file mode 100644 index 00000000..a67af23f --- /dev/null +++ b/package-lock.json @@ -0,0 +1,26 @@ +{ + "name": "blessed", + "version": "0.1.81", + "lockfileVersion": 1, + "requires": true, + "dependencies": { + "nan": { + "version": "2.14.0", + "resolved": "https://registry.npmjs.org/nan/-/nan-2.14.0.tgz", + "integrity": "sha512-INOFj37C7k3AfaNTtX8RhsTw7qRy7eLET14cROi9+5HAVbbHuIWUHEauBv5qT4Av2tWasiTY1Jw6puUNqRJXQg==" + }, + "node-pty": { + "version": "0.9.0", + "resolved": "https://registry.npmjs.org/node-pty/-/node-pty-0.9.0.tgz", + "integrity": "sha512-MBnCQl83FTYOu7B4xWw10AW77AAh7ThCE1VXEv+JeWj8mSpGo+0bwgsV+b23ljBFwEM9OmsOv3kM27iUPPm84g==", + "requires": { + "nan": "^2.14.0" + } + }, + "term.js": { + "version": "0.0.7", + "resolved": "https://registry.npmjs.org/term.js/-/term.js-0.0.7.tgz", + "integrity": "sha1-Um8kz8Dy72+A9RfJ4n2ulHvIcxU=" + } + } +} diff --git a/package.json b/package.json index 7e923b39..0f9f91b0 100644 --- a/package.json +++ b/package.json @@ -2,14 +2,15 @@ "name": "blessed", "description": "A high-level terminal interface library for node.js.", "author": "Christopher Jeffrey", - "version": "0.1.81", + "contributors": ["danikaze "], + "version": "0.1.82", "license": "MIT", "main": "./lib/blessed.js", "bin": "./bin/tput.js", "preferGlobal": false, - "repository": "git://github.com/chjj/blessed.git", - "homepage": "https://github.com/chjj/blessed", - "bugs": { "url": "http://github.com/chjj/blessed/issues" }, + "repository": "git://github.com/danikaze/blessed.git", + "homepage": "https://github.com/danikaze/blessed", + "bugs": { "url": "http://github.com/danikaze/blessed/issues" }, "keywords": ["curses", "tui", "tput", "terminfo", "termcap"], "tags": ["curses", "tui", "tput", "terminfo", "termcap"], "engines": { @@ -17,5 +18,9 @@ }, "browserify": { "transform": ["./browser/transform.js"] + }, + "dependencies": { + "node-pty": "^0.9.0", + "term.js": "0.0.7" } } diff --git a/vendor/tng.js b/vendor/tng.js index 731ef6c7..ba2119c8 100644 --- a/vendor/tng.js +++ b/vendor/tng.js @@ -29,7 +29,7 @@ function PNG(file, options) { if (!file) throw new Error('no file'); this.options = options || {}; - this.colors = options.colors || require('blessed/lib/colors'); + this.colors = options.colors || require('../lib/colors') this.optimization = this.options.optimization || 'mem'; this.speed = this.options.speed || 1;