返回 后端
Awesome cross platform nodejs
Resources¶
- Core Node.js documentation - 特别是
os,path,fs,process和child_process模块. - Cross-platform Node.js guide - 如何编写跨平台的 Node.js 代码.
- Microsoft Node.js Guidelines - 在 Microsoft 平台上使用 Node.js 的提示、技巧和资源.
- Writing Cross-Platform Node.js - 很棒的教程,涵盖了编写跨平台代码时出现的许多常见问题:路径创建、脚本执行、换行符.
- Cross-platform terminal characters - 适用于大多数终端和大多数操作系统的所有字符.
Applications¶
Development environment¶
- Node.js - 适用于各种平台的 Node.js 安装程序.
- nvm-windows - 在 Windows 计算机上管理 Node.js 的多个安装.
- nvm / n - macOS/Linux 的节点版本管理器.
- npm-windows-upgrade - 在 Windows 上升级 npm.
- windows-build-tools - 使用 npm 安装适用于 Windows 的 C++ 构建工具.
Continuous integration¶
- AppVeyor - 专注于 Windows. OSS 项目可以使用免费套餐.
- Travis - Windows/macOS/Linux. OSS 项目免费.
- Azure Pipelines - Windows/macOS/Linux. 对于具有 10 个并行作业的 OSS 项目免费.
- Github Action - Windows/macOS/Linux. GitHub Actions 可以轻松实现所有软件工作流程的自动化.
- Gitlab CI - Windows/macOS/Linux. GitLab CI/CD 是 GitLab 内置的用于软件开发的工具.
Virtualization¶
- ievms - Microsoft 提供的免费虚拟机映像的自动安装程序,用于在多个版本的 IE 上进行测试. 这些图像可用于跨平台测试各种技术,但请确保您阅读并理解 Microsoft 的许可.
- VirtualBox - 用于运行 x86 虚拟机的通用软件.
- Docker - 用于在通用操作系统上创建、部署和管理虚拟化应用程序容器的软件平台,具有联合工具的生态系统.
Compatibility¶
- Wine - 在 Linux、Mac、BSD 和 Solaris 上运行 Windows API 调用.
- Cygwin - 在 Windows 上运行 POSIX.
- WSL - 在 Windows 上运行 Linux 命令行(ELF 二进制执行、系统调用、文件系统、Bash、核心实用程序、常见应用程序).
- MinGW - Windows 上的
gcc. - msys / Git Bash - 在 Windows 上重击.
Databases¶
- Redis - 适用于 Windows 的 Redis 本机端口.
Libraries¶
OS identification¶
- is-windows - 检测当前平台是否为Windows.
- is-wsl - 检测当前平台是否为 WSL(Linux 的 Windows 子系统).
- getos - 检索当前操作系统,包括 Linux 发行版.
- os-name - 获取当前操作系统的名称.
- systeminformation - 硬件/软件系统信息.
Shell¶
- execa -
child_process.{execFile,exec}的跨平台实现. - gulp-execa - Gulp.js 中的跨平台命令执行.
- cross-spawn -
child_process.spawn()的跨平台实现. - shelljs - 跨平台的 Unix shell 命令.
- node-windows - Windows 支持 Node.js 脚本(守护进程、事件日志、UAC 等).
- log-symbols - 带有 Windows 回退的各种日志级别的彩色符号.
- figures - 带有 Windows 回退的 Unicode 符号.
- clipboardy / clipboard-cli - Cross-platform copy/paste.
Environment¶
- cross-env - 跨平台设置环境变量.
- user-home - 获取用户主目录的路径. 跨平台.
- username - 获取当前用户名.
- osenv - 跨平台环境变量.
- is-elevated - 检查进程是否以提升的权限运行.
- which - Unix
which的跨平台实现.
Filesystem¶
- rimraf / del - 删除文件和文件夹. 跨平台.
- make-dir - 跨平台“mkdir -p”.
- readdirp -
fs.readdir()的递归版本. - cpy - 复制文件. 跨平台.
- chokidar - 改进了跨平台文件观看.
- graceful-fs - 改进了
fs模块,尤其是在 Windows 上. - fs-extra - 将
graceful-fs与更好的 JSON 文件读取和承诺相结合. - any-path - 从对象中获取值时,可互换使用 Windows 和 POSIX 路径.
- dev-null-cli - 跨平台
/dev/null. - global-cache-dir - 获取全局特定于操作系统的缓存目录.
Signals¶
- fkill - 杀死进程. 跨平台.
- signal-exit - 跨平台的“退出”处理程序.
- human-signals - 人性化的过程信号.
Processes¶
- ps-list - 获取正在运行的进程.
- process-exists - 检查进程是否存在.
Streams¶
- noop-stream - 跨平台
fs.createReadStream('/dev/null'). - random-bytes-readable-stream - 跨平台
fs.createReadStream('/dev/urandom').
Desktop UI¶
- open - 打开网站、文件、可执行文件等内容. 跨平台.
- node-notifier - 跨平台桌面通知.
Windows registry¶
- node-winreg - 访问 Windows 注册表.
- rage-edit - 访问/修改 Windows 注册表.
- windows-registry-node - 访问/修改 Windows 注册表并设置文件关联.
Known issues¶
- cmd.exe unicode woes - 默认情况下,
cmd.exe在 Windows 上不显示 Unicode 字符. - spawn issues -
child_process.spawn()行为在 Windows 和 Linux 之间不一致. - exec() behavior between shells - 根据所使用的 shell,例如 bash 与 dash,
child_process.exec()具有不一致的退出行为.
See also¶
- awesome-desktop-js - 在桌面上构建 JavaScript 应用程序的工具列表.
Support¶
如果您发现错误或想添加更多信息,不要犹豫 submit an issue on GitHub.
无论个人背景如何,都欢迎大家. 我们强制执行 Code of conduct 为了促进积极和 包容的环境.
Contributing¶
这个项目是用❤️制作的. 最简单的回馈方式是主演和 在线分享.
如果文档不清楚或有错字,请点击页面的“编辑” 按钮(铅笔图标)并提出更正建议.
如果您想帮助我们修复错误或添加更多信息,请检查 our guidelines . 欢迎请求请求!
感谢这些优秀的人:
Benjamin E. Coe 💻 🤔 📖 | ehmicky 💻 🤔 📖 | Sindre Sorhus 💻 🤔 📖 | Hongarc 🎨 📖 💻 | Kent C. Dodds 🤔 | 杰森·库克 | 亚伦哈夫纳 |
贝莱斯 | Xiaodan Mao | 詹姆斯·塔尔马奇 | 西尔万庞托罗 | Steven 🤔 |
该项目遵循 all-contributors 规格.
