🚀 Features / API
- New events API that is easier to use and plays nicer with TypeScript (#283) via @Tyriar
pty.onData(d => console.log(d)); pty.onExit(e => console.log(e.exitCode, e.signal));
colsandrowsare now exposed onIPty(#290) via @Tyriarconsole.log(pty.cols, pty.rows)
- Experimental flow control APIs are available (#304, #364) via @jerch. Note that they may be removed in the future, see node-pty.d.ts for details and xtermjs/xterm.js#2077 for discussion
- Promoted conpty support to stable and removed
experimentalfrom name (#365) via @Tyriar// before const pty = spawn(file, args, { experimentalUseConpty: true }); // after const pty = spawn(file, args, { useConpty: true });
- Allow specifying the
PSEUDOCONSOLE_INHERIT_CURSORconpty flag withIWindowsPtyForkOptions.conptyInheritCursor(#309) via @Tyriar
⬆️ Dependencies
🐞 Bug fixes
- Fix passing
nullasencodingto use raw buffers (#273, #362) via @anszom, @Tyriar - Provide better error message when ioctl fails (#285) via @Tyriar
- Restore default ctrl+c handler in conpty support (#287) via @Tyriar
- Mark several APIs as
readonly(#308) via @Tyriar - Fix crash when using conpty on 32-bit Windows (#314) via @ZoeyR
- Fix handle inheritance for shells (#334) via @ZoeyR
- Re-throw release binary require exception when debug require fails (#340) via @Tyriar
- Avoid specifying
/usr/*/libunder libraries (#343) via @deepak1556 - Fix compilation when
VWERASE/VDISCARDare named differently (#358) via @ThePrez - Protect calling resize with invalid values from crashing winpty (#363) via @Tyriar
📝 Documentation and internal improvements
- Remove dynamic loading so bundlers can work more effectively (#274) via @implausible
- Update electron example dependencies (#275, #291, #299, #315, #355) via @Tyriar
- Remove unneeded @types/ps-list dependency (#280) via @coderaiser
- Support node v12 (#288, #331) via @Eugeny, @deepak1556
- Git ignore VS Code CPP+ extension data directory (#292) via @Tyriar
- Automate releasing of beta and stable builds (#294) via @Tyriar
- Correct badge link in README (#295) via @Tyriar
- Correct usage of prepublish npm script (#298) via @coderaiser
- Remove chatty log message (#301) via @coderaiser
- Formatting/refactoring (#305, #310, #311) via @Tyriar, @jerch
- Support node v8 (#313) via @ZoeyR
- Upgrade to @types/node@8 (#321) via @Tyriar
- Support electron v6 (v8 7.6) (#322) via @deepak1556
- Upgrade nan (#336) via @deepak1556
- Upgrade lodash (#341) via @dependabot
- Remove pollUntil dependency and add vscode unit test debug target (#342) via @Tyriar
⚠️ Deprecations
- The
onevent format is now deprecated and will be removed in v1 (#283) via @Tyriar// deprecated pty.on('data', d => console.log(d)); // recommended pty.onData(d => console.log(d));
🎉 New real-world use cases
- Electerm (#270) via @zxdong262
- Extraterm (#276) via @sedwards2009
- Wetty (#302) via @koushikmln