What is this?
zx is a tool from Google that lets you write shell scripts in JavaScript instead of Bash, wrapping Node's child_process with argument escaping and sensible defaults.
Is this a library I import or a standalone CLI tool?
Both: zx is a JS/TS package you can import into your own code, and it also ships a CLI that runs .mjs scripts directly, giving you a global $ template tag for shell commands.
How do I get started with it?
Install the zx package and write scripts using the $ tagged template to run shell commands; full setup options are documented at zx/setup and usage docs live at google.github.io/zx.
What runtime do I need to run zx scripts?
Node.js >= 12.17.0 is the baseline, but it also runs on Bun >= 1.0.0, Deno 1.x/2.x, or GraalVM Node.js, and works alongside Bash or PowerShell.
Does it only support one module format?
No, it supports both CommonJS and ESM modules, and you can write scripts in either plain JavaScript or TypeScript.
Does it work on Windows too, or just Unix-like systems?
It runs cross-platform on Linux, macOS, and Windows, using PowerShell on Windows and Bash on Unix-like systems.
Is this an official Google product?
It's licensed under Apache-2.0 but explicitly not an officially supported Google product, despite living under the google GitHub org.
What is MAML, which is mentioned in the README?
MAML is a related project also referenced in the zx README: a JSON-like config format that adds comments, multiline strings, unquoted keys, and optional commas.
Why would I use zx instead of plain Bash scripting?
zx lets you use a full programming language (JavaScript/TypeScript) with real data structures and error handling for complex scripts, while still giving you convenient shell-command execution without the usual Node.js child_process boilerplate.
What are similar projects?
shelljs, terminalizer, inshellisense, navi, asdf, npm-check-updates, Inquirer.js, deno
Which topics is it in?
deno, scripting, powershell, bun, bash, node, shell, command-line, npm, terminal, automation, tool