
Security News
Attackers Are Hunting High-Impact Node.js Maintainers in a Coordinated Social Engineering Campaign
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.
@karinjs/node-pty
Advanced tools
一个轻量级的 node-pty 预编译包,基于 @homebridge/node-pty-prebuilt-multiarch 优化。
English | 简体中文
[!WARNING] 目前仅在 Windows Node.js 环境下完成测试。其他环境(Linux、macOS 等)的兼容性需要用户自行验证。如遇到问题,欢迎反馈。
使用 npm:
npm install @karinjs/node-pty
使用 yarn:
yarn add @karinjs/node-pty
使用 pnpm:
pnpm add @karinjs/node-pty
使用别名安装:
npm install node-pty:@karinjs/node-pty
# or
npm install @homebridge/node-pty-prebuilt-multiarch:@karinjs/node-pty
| 操作系统 | 架构 |
|---|---|
| macOS | x64, arm64 |
| Linux (glibc) | ia32, x64, armv6, aarch64 |
| Linux (musl) | x64, armv6, aarch64 |
| Windows | ia32, x64 |
注意: 仅支持 Node.js 16+ 和 Electron 16.0.0+ 版本(不含 Electron 28)
由于采用预编译的方式分发,包的安装依赖于网络环境的稳定性。如果遇到下载问题,可以:
| @karinjs/node-pty | @homebridge/node-pty-prebuilt-multiarch |
|---|---|
| 1.0.2 | 0.11.14 |
本项目基于以下优秀的开源项目:
本项目基于 MIT 协议开源。感谢以下项目的贡献:
import * as os from "node:os";
import * as pty from "@karinjs/node-pty";
async function run() {
const shell = os.platform() === "win32" ? "powershell.exe" : "bash";
const ptyProcess = pty.spawn(shell, [], {
name: "xterm-color",
cols: 80,
rows: 30,
cwd: process.env.HOME,
env: process.env,
});
ptyProcess.onData((data) => {
process.stdout.write(data);
});
ptyProcess.write("ls\r");
ptyProcess.resize(100, 40);
ptyProcess.write("ls\r");
}
run();
FAQs
Fork pseudoterminals in Node.JS
The npm package @karinjs/node-pty receives a total of 65 weekly downloads. As such, @karinjs/node-pty popularity was classified as not popular.
We found that @karinjs/node-pty demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 2 open source maintainers collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
Multiple high-impact npm maintainers confirm they have been targeted in the same social engineering campaign that compromised Axios.

Security News
Axios compromise traced to social engineering, showing how attacks on maintainers can bypass controls and expose the broader software supply chain.

Security News
Node.js has paused its bug bounty program after funding ended, removing payouts for vulnerability reports but keeping its security process unchanged.