google/zx
Fork: 1276 Star: 45525 (更新于 2026-06-09 03:00:33)
license: Apache-2.0
Language: JavaScript .
最后发布版本: 8.8.5 ( 2025-10-19 21:47:33)
A tool for writing better scripts
zx
#!/usr/bin/env zx
await $`cat package.json | grep name`
const branch = await $`git branch --show-current`
await $`dep deploy --branch=${branch}`
await Promise.all([
$`sleep 1; echo 1`,
$`sleep 2; echo 2`,
$`sleep 3; echo 3`,
])
const name = 'foo bar'
await $`mkdir /tmp/${name}`
Bash is great, but when it comes to writing more complex scripts,
many people prefer a more convenient programming language.
JavaScript is a perfect choice, but the Node.js standard library
requires additional hassle before using. No compromise, take the best of both. The zx package provides
useful cross-platform wrappers around child_process, escapes arguments and
gives sensible defaults.
Install
npm install zx
All setup options: zx/setup. See also zx@lite.
Usage
Compatibility
- Linux, macOS, or Windows
- JavaScript Runtime:
- Node.js >= 12.17.0
- Bun >= 1.0.0
- Deno 1.x, 2.x
- GraalVM Node.js
- Some kind of bash or PowerShell
- Both CJS or ESM modules in JS or TS
See also
- 🔥 crow.watch — a computing-focused community, link aggregation and discussion, join.
License
Disclaimer: This is not an officially supported Google product.
最近版本更新:(数据更新于 2026-04-10 14:33:28)
2025-10-19 21:47:33 8.8.5
2025-09-27 04:56:26 8.8.4
2025-09-20 21:25:03 8.8.3
2025-09-20 05:09:40 8.8.2
2025-08-21 00:22:41 8.8.1
2025-08-05 22:01:02 8.8.0
2025-07-29 20:40:57 8.7.2
2025-07-14 22:30:24 8.7.1
2025-07-12 04:12:38 8.7.0
2025-07-09 22:10:57 8.6.2
主题(topics):
javascript cli nodejs bash shell child-process exec pipe spawn
google/zx同语言 JavaScript最近更新仓库
2026-06-11 16:12:28 zone-eu/wildduck
2026-06-11 03:50:10 code-dot-org/code-dot-org
2026-06-11 01:06:25 gorhill/uBlock
2026-06-10 02:04:57 gethomepage/homepage
2026-06-09 14:02:38 codeceptjs/CodeceptJS
2026-06-09 03:38:23 dotenvx/dotenvx