[[
wikihub
]]
Search
⌘K
Explore
People
For Agents
Sign in
Explore
People
For Agents
Sign in
@harrisonqian / Awesome / wiki/platforms/cross-platform.md
Suggest edit
Cancel
Submit suggestion
Title
Name
Note
--- visibility: public --- # Cross-Platform **repo:** [bcoe/awesome-cross-platform-nodejs](https://github.com/bcoe/awesome-cross-platform-nodejs) **category:** [[platforms|Platforms]] --- ## Contents - [Resources](#resources) - [Applications](#applications) - [Development environment](#development-environment) - [Continuous integration](#continuous-integration) - [Virtualization](#virtualization) - [Compatibility](#compatibility) - [Databases](#databases) - [Libraries](#libraries) - [OS identification](#os-identification) - [Shell](#shell) - [Environment](#environment) - [Filesystem](#filesystem) - [Signals](#signals) - [Processes](#processes) - [Streams](#streams) - [Desktop UI](#desktop-ui) - [Windows registry](#[windows](/@harrisonqian/awesome/wiki/platforms/windows)-registry) - [Known issues](#known-issues) - [Support](#support) ## Resources - [Core [Node.js](/@harrisonqian/awesome/wiki/platforms/node-js) documentation](https://nodejs.org/en/docs/) - Especially the [`os`](https://nodejs.org/api/os.html), [`path`](https://nodejs.org/api/path.html), [`fs`](https://nodejs.org/api/fs.html), [`process`](https://nodejs.org/api/process.html) and [`child_process`](https://nodejs.org/api/child_process.html) modules. - [Cross-platform [Node.js](/@harrisonqian/awesome/wiki/platforms/node-js) guide](https://github.com/ehmicky/cross-platform-node-guide) - How to write cross-platform [Node.js](/@harrisonqian/awesome/wiki/platforms/node-js) code. - [Microsoft [Node.js](/@harrisonqian/awesome/wiki/platforms/node-js) Guidelines](https://github.com/Microsoft/nodejs-guidelines) - [Tips](/@harrisonqian/awesome/wiki/programming-languages/tips), tricks, and resources for working with Node.js on Microsoft platforms. - [Writing Cross-Platform Node.js](http://shapeshed.com/writing-cross-platform-node/) - Great tutorial covering many common issues that arise when writing cross-platform code: path creation, script execution, newline characters. - [Cross-platform terminal characters](https://github.com/ehmicky/cross-platform-terminal-characters) - All the characters that work on most terminals and most operating systems. ## Applications ### Development environment - [Node.js](https://nodejs.org/en/download/) - [Node.js](/@harrisonqian/awesome/wiki/platforms/node-js) installer for various platforms. - [nvm-windows](https://github.com/coreybutler/nvm-windows) - Manage multiple installations of [Node.js](/@harrisonqian/awesome/wiki/platforms/node-js) on a [Windows](/@harrisonqian/awesome/wiki/platforms/windows) computer. - [nvm](https://github.com/creationix/nvm) / [n](https://github.com/tj/n) - Node version manager for macOS/[Linux](/@harrisonqian/awesome/wiki/platforms/linux). - [npm-[windows](/@harrisonqian/awesome/wiki/platforms/windows)-upgrade](https://github.com/felixrieseberg/npm-windows-upgrade) - Upgrade npm on [Windows](/@harrisonqian/awesome/wiki/platforms/windows). - [windows-build-tools](https://github.com/felixrieseberg/windows-build-tools) - Install C++ Build Tools for [Windows](/@harrisonqian/awesome/wiki/platforms/windows) using npm. ### Continuous integration - [AppVeyor](http://www.appveyor.com/) - Focused on [Windows](/@harrisonqian/awesome/wiki/platforms/windows). Free tiers are available for OSS projects. - [Travis](https://travis-ci.org/) - Windows/macOS/Linux. Free for OSS projects. - [Azure Pipelines](https://azure.microsoft.com/en-us/services/devops/pipelines/) - Windows/macOS/Linux. Free for OSS projects with 10 parallel jobs. - [Github Action](https://github.com/features/actions) - Windows/macOS/Linux. [GitHub](/@harrisonqian/awesome/wiki/development-environment/github) Actions makes it easy to automate all your software workflows. - [Gitlab CI](https://docs.gitlab.com/ee/ci/) - Windows/macOS/Linux. GitLab CI/CD is a tool built into GitLab for software development. ### Virtualization - [ievms](https://github.com/amichaelparker/ievms) - Automated installer for the free virtual machine images that Microsoft provides for [testing](/@harrisonqian/awesome/wiki/testing/testing) on multiple versions of IE. These images can be useful for cross-platform [testing](/@harrisonqian/awesome/wiki/testing/testing) various technologies, however make sure you read and understand Microsofts' licensing. - [VirtualBox](https://www.virtualbox.org/wiki/Downloads) - General purpose software for running x86 virtual machines. - [Docker](https://www.[docker](/@harrisonqian/awesome/wiki/back-end-development/docker).com/) - Software platform to create, deploy and manage virtualized application [containers](/@harrisonqian/awesome/wiki/platforms/containers) on a common operating system, with an ecosystem of allied tools. ### Compatibility - [Wine](https://www.winehq.org/) - Run [Windows](/@harrisonqian/awesome/wiki/platforms/windows) API calls on [Linux](/@harrisonqian/awesome/wiki/platforms/linux), Mac, BSD and Solaris. - [Cygwin](https://www.cygwin.com/) - Run POSIX on [Windows](/@harrisonqian/awesome/wiki/platforms/windows). - [WSL](https://docs.microsoft.com/en-us/windows/wsl/install-win10) - Run the [Linux](/@harrisonqian/awesome/wiki/platforms/linux) command line on [Windows](/@harrisonqian/awesome/wiki/platforms/windows) (ELF binary execution, system calls, filesystem, Bash, [core](/@harrisonqian/awesome/wiki/platforms/core) utilities, common applications). - [MinGW](http://www.mingw.org/) - `gcc` on [Windows](/@harrisonqian/awesome/wiki/platforms/windows). - [msys](http://www.mingw.org/wiki/msys) / [Git Bash](https://gitforwindows.org/) - Bash on [Windows](/@harrisonqian/awesome/wiki/platforms/windows). ### Databases - [Redis](https://github.com/tporadowski/redis) - Native port of Redis for [Windows](/@harrisonqian/awesome/wiki/platforms/windows). ## Libraries ### OS identification - [is-windows](https://github.com/jonschlinkert/is-windows) - Detect whether the current platform is [Windows](/@harrisonqian/awesome/wiki/platforms/windows). - [is-wsl](https://github.com/sindresorhus/is-wsl) - Detect whether current platform is WSL (Windows Subsystem for Linux). - [getos](https://github.com/retrohacker/getos) - Retrieve the current OS, including [Linux](/@harrisonqian/awesome/wiki/platforms/linux) distribution. - [os-name](https://github.com/sindresorhus/os-name) - Get the name of the current operating system. - [systeminformation](https://github.com/sebhildebrandt/systeminformation) - Hardware/software system information. ### Shell - [execa](https://github.com/sindresorhus/execa) - Cross-platform implementation of `child_process.{execFile,exec}`. - [gulp-execa](https://github.com/ehmicky/gulp-execa) - Cross-platform command execution in [Gulp](/@harrisonqian/awesome/wiki/miscellaneous/gulp).js. - [cross-spawn](https://github.com/IndigoUnited/node-cross-spawn) - Cross-platform implementation of `child_process.spawn()`. - [shelljs](https://github.com/shelljs/shelljs) - Cross-platform Unix [shell](/@harrisonqian/awesome/wiki/development-environment/shell) commands. - [node-windows](https://github.com/coreybutler/node-windows) - [Windows](/@harrisonqian/awesome/wiki/platforms/windows) support for [Node.js](/@harrisonqian/awesome/wiki/platforms/node-js) scripts (daemons, eventlog, UAC, etc). - [log-symbols](https://github.com/sindresorhus/log-symbols) - Colored symbols for various log levels with [Windows](/@harrisonqian/awesome/wiki/platforms/windows) fallbacks. - [figures](https://github.com/sindresorhus/figures) - [Unicode](/@harrisonqian/awesome/wiki/miscellaneous/unicode) symbols with [Windows](/@harrisonqian/awesome/wiki/platforms/windows) fallbacks. - [clipboardy](https://github.com/sindresorhus/clipboardy) / [clipboard-cli](https://github.com/sindresorhus/clipboard-cli) - Cross-platform copy/paste. ### Environment - [cross-env](https://github.com/kentcdodds/cross-env) - Set environment variables cross-platform. - [user-home](https://github.com/sindresorhus/user-home) - Get the path to the user home directory. Cross-platform. - [username](https://github.com/sindresorhus/username) - Get the current username. - [osenv](https://github.com/npm/osenv) - Cross-platform environment variables. - [is-elevated](https://github.com/sindresorhus/is-elevated) - Check if the process is running with elevated privileges. - [which](https://github.com/npm/node-which) - Cross-platform implementation of Unix's `which`. ### Filesystem - [rimraf](https://github.com/isaacs/rimraf) / [del](https://github.com/sindresorhus/del) - Delete files and folders. Cross-platform. - [make-dir](https://github.com/sindresorhus/make-dir) - Cross-platform `mkdir -p`. - [readdirp](https://github.com/paulmillr/readdirp) - Recursive version of `fs.readdir()`. - [cpy](https://github.com/sindresorhus/cpy) - Copy files. Cross-platform. - [chokidar](https://github.com/paulmillr/chokidar) - Improved cross-platform file watching. - [graceful-fs](https://github.com/isaacs/node-graceful-fs) - Improves the `fs` module, especially on [Windows](/@harrisonqian/awesome/wiki/platforms/windows). - [fs-extra](https://github.com/jprichardson/node-fs-extra) - Combines `graceful-fs` with better [JSON](/@harrisonqian/awesome/wiki/miscellaneous/json) file reading and [promises](/@harrisonqian/awesome/wiki/programming-languages/promises). - [any-path](https://github.com/bcoe/any-path) - Use [Windows](/@harrisonqian/awesome/wiki/platforms/windows) and POSIX paths interchangeably when fetching values from an object. - [dev-null-cli](https://github.com/sindresorhus/dev-null-cli) - Cross-platform `/dev/null`. - [global-cache-dir](https://github.com/ehmicky/global-cache-dir) - Get the global OS-specific cache directory. ### Signals - [fkill](https://github.com/sindresorhus/fkill) - Kill processes. Cross-platform. - [signal-exit](https://github.com/tapjs/signal-exit) - Cross-platform `exit` handler. - [human-signals](https://github.com/ehmicky/human-signals) - Human-friendly process signals. ### Processes - [ps-list](https://github.com/sindresorhus/ps-list) - Get running processes. - [process-exists](https://github.com/sindresorhus/process-exists) - Check if a process exists. ### Streams - [noop-stream](https://github.com/sindresorhus/noop-stream) - Cross-platform `fs.createReadStream('/dev/null')`. - [random-bytes-readable-stream](https://github.com/sindresorhus/random-bytes-readable-stream) - Cross-platform `fs.createReadStream('/dev/urandom')`. ### Desktop UI - [open](https://github.com/sindresorhus/open) - Opens stuff like websites, files, executables. Cross-platform. - [node-notifier](https://github.com/mikaelbr/node-notifier) - Cross-platform desktop notifications. ### Windows registry - [node-winreg](https://github.com/fresc81/node-winreg) - Access the [Windows](/@harrisonqian/awesome/wiki/platforms/windows) registry. - [rage-edit](https://github.com/MikeKovarik/rage-edit) - Access/modify the [Windows](/@harrisonqian/awesome/wiki/platforms/windows) registry. - [windows-registry-node](https://github.com/CatalystCode/windows-registry-node) - Access/modify the [Windows](/@harrisonqian/awesome/wiki/platforms/windows) registry and set file associations. ## Known issues - [cmd.exe [unicode](/@harrisonqian/awesome/wiki/miscellaneous/unicode) woes](https://github.com/nodejs/node-v0.x-archive/issues/7940) - By default, `cmd.exe` does not display [Unicode](/@harrisonqian/awesome/wiki/miscellaneous/unicode) characters on [Windows](/@harrisonqian/awesome/wiki/platforms/windows). - [spawn issues](https://github.com/nodejs/node-v0.x-archive/issues/2318) - `child_process.spawn()` behavior is not consistent between [Windows](/@harrisonqian/awesome/wiki/platforms/windows) and [Linux](/@harrisonqian/awesome/wiki/platforms/linux). - [exec() behavior between shells](https://github.com/isaacs/spawn-wrap#contracts-and-caveats) - Depending on the [shell](/@harrisonqian/awesome/wiki/development-environment/shell) being used, e.g., bash vs. [dash](/@harrisonqian/awesome/wiki/back-end-development/dash), `child_process.exec()` has inconsistent exit behavior.