dax — cross-platform shell tools for Deno and Node.js
Dax is a cross-platform shell tool designed for Deno and Node.js, providing a consistent scripting experience across different operating systems. It includes built-in commands and features that enhance usability, such as automatic argument escaping and structured output. Dax aims to simplify shell scripting while ensuring safety and portability without native dependencies.
- ▪Dax runs the same on macOS, Linux, and Windows, offering common commands for better compatibility.
- ▪It automatically escapes template literal interpolations to prevent shell-injection bugs.
- ▪Dax includes features like prompts, progress bars, and an immutable Path API, all in pure TypeScript and WebAssembly.
Opening excerpt (first ~120 words) tap to expand
v0.48.2 dax — shell scriptingthat runs the same everywhere. Cross-platform shell tools for Deno and Node.js inspired by zx — a friendlier $ for spawning processes, with a built-in shell, built-in commands, prompts, requests, and a Path API. JSR@david/dax npmdax Get started Shell reference Star on GitHub import $ from "dax"; $.logStep("Building"); await $`deno task build`; const env = await $.select({ message: "Where to?", options: ["staging", "production"], }); const branch = await $`git rev-parse --abbrev-ref HEAD`.text(); $.logLight(`Deploying ${branch} → ${env.value}`); await $.all([ $`deno task deploy ${env.value} api`, $`deno task deploy ${env.value} web`, ]); $.logStep("Deployed"); Highlights # Cross-platform shell Same shell on macOS, Linux, and Windows.
…
Excerpt limited to ~120 words for fair-use compliance. The full article is at Dax.