Skip to Content
gnux

Guides

Task-oriented guides for gnux, a portable, GNU-compatible implementation of the GNU core utilities' interface in Go: one statically linked binary that carries 108 tools, a Go library with an importable engine for every tool, and a portable shell that runs the same script on Linux, macOS and Windows. The reference pages describe each tool's flags one by one; these guides show how to put the tools to work, with hundreds of runnable examples, complete scripts, CI configurations and Go programs. The gnux command lines and shell scripts were run against a real gnux build, the outputs shown are captured from it, and every Go program was compiled and run.

Pick a guide

GuideForWhat you get
Getting startedEveryoneEvery way to install, linking the tool names, the two invocation forms, GNU-name aliases, --help, --version and --list
CookbookCommand-line usersOver 90 recipes grouped by task: inspecting files, copying and linking, safe deletion, backups, logs, paths, environment, timestamps, generated data and pipelines
Portable scriptingScript and build authorsThe gnux shell language in depth and four complete scripts (scaffold, clean, log rotation, release staging) that behave identically on every platform
Windows and PowerShellWindows usersInstalling on Windows, links versus copies of gnux.exe, PowerShell's colliding aliases, quoting, and what degrades on NTFS
Sandbox and AI agentsAnyone running scripts or agents they do not fully trustgnux shell --sandbox, gnux mcp for Claude Code, Claude Desktop, Cursor and VS Code, what is reachable on each platform, and the limits
Node and npmJavaScript and TypeScript developersInstalling from npm, replacing rimraf, mkdirp, cpy-cli, shx and cross-env in package scripts, globs on Windows, and the JavaScript API
CI and containersCI and DevOps engineersGitHub Actions, GitLab CI and Docker recipes, and one gnux shell script as a cross-OS build step
Go libraryGo developersEmbedding the engines: options, streams, captured output, injected prompts and clocks, errors, cmd.RunTool, cmd.NewShell, and seventeen complete programs
Terminal viewEveryone at a terminalThe terminal view: colored columns, trees, icons, git status, usage bars, grep headings, colored checks and reports, dark and light themes, and making your choices the default
AdoptionUsers of GNU coreutilsAll 108 tools side by side with their GNU counterparts, supported flags, every documented deviation and what is not implemented yet
TroubleshootingEveryoneWhat each error and exit status means, prompts you did not expect, refusals, and a FAQ

By task

I want to...Read
Install gnux and run my first commandGetting started
Use rmx, cpx and lsx on WindowsWindows and PowerShell
Find the right flags for an everyday jobCookbook
Replace a pile of .sh and .ps1 files with one scriptPortable scripting
Replace rimraf, mkdirp and shx in my package scriptsNode and npm
Let an AI agent manage files in one project and nowhere elseSandbox and AI agents
Run the same build step on Linux, macOS and Windows runnersCI and containers
Delete, copy or list files from a Go program without spawning a processGo library
See a colored tree of a project, with git status, and pick a themeTerminal view
Adopt gnux next to the GNU tools I already use, and know where it differsAdoption
Understand an error message or an exit statusTroubleshooting

Elsewhere in the documentation

On this page