Help us shape the future of Go! Take the 2026 Go Developer Survey

builtins

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 5, 2026 License: MIT Imports: 117 Imported by: 0

Documentation

Overview

Package builtins is the meta-package that side-effect-imports every Phase 10 built-in. Each command's init() calls command.RegisterBuiltin, populating the package-level slice that gobash.New consumes when constructing a *Bash.

Hosts that want the full default registry should not import this package directly — the gobash root package blank-imports it via builtins_init.go. Hosts that want a CUSTOM subset (e.g. only `echo` and `printf`) should set BashOptions.Commands to filter.

Hosts that want NO built-ins at all must construct a *Bash and then drop entries from Bash.Registry() manually; the blank import here is not conditional.

Cited surface: the spec ("Lazy loading" — Go has no dynamic import, so we replace it with side-effect registration).

Directories

Path Synopsis
Package alias implements the `alias` built-in.
Package alias implements the `alias` built-in.
Package awk implements the `awk` built-in.
Package awk implements the `awk` built-in.
Package base64 implements the `base64` built-in.
Package base64 implements the `base64` built-in.
Package basename implements the `basename` built-in.
Package basename implements the `basename` built-in.
Package bash implements the `bash` built-in.
Package bash implements the `bash` built-in.
Package breakcmd implements the `break` shell built-in.
Package breakcmd implements the `break` shell built-in.
Package cat implements the `cat` built-in.
Package cat implements the `cat` built-in.
Package cd implements the `cd` shell built-in.
Package cd implements the `cd` shell built-in.
Package chmod implements the `chmod` built-in.
Package chmod implements the `chmod` built-in.
Package clear implements the `clear` built-in.
Package clear implements the `clear` built-in.
Package colon implements the `:` (colon) shell built-in.
Package colon implements the `:` (colon) shell built-in.
Package column implements the `column` built-in.
Package column implements the `column` built-in.
Package comm implements the `comm` built-in.
Package comm implements the `comm` built-in.
Package compgen implements the `compgen` shell built-in.
Package compgen implements the `compgen` shell built-in.
Package complete implements the `complete` shell built-in.
Package complete implements the `complete` shell built-in.
Package compopt implements the `compopt` shell built-in.
Package compopt implements the `compopt` shell built-in.
Package continuecmd implements the `continue` shell built-in.
Package continuecmd implements the `continue` shell built-in.
Package cp implements the `cp` built-in.
Package cp implements the `cp` built-in.
Package curl implements the `curl` built-in.
Package curl implements the `curl` built-in.
Package cut implements the `cut` built-in.
Package cut implements the `cut` built-in.
Package date implements the `date` built-in.
Package date implements the `date` built-in.
Package declare implements the `declare` shell built-in.
Package declare implements the `declare` shell built-in.
Package diff implements the `diff` built-in.
Package diff implements the `diff` built-in.
Package dirname implements the `dirname` built-in.
Package dirname implements the `dirname` built-in.
Package dirs implements the `dirs` shell built-in.
Package dirs implements the `dirs` shell built-in.
Package du implements the `du` built-in.
Package du implements the `du` built-in.
Package echo implements the `echo` built-in.
Package echo implements the `echo` built-in.
Package egrep implements the `egrep` built-in — grep with the extended-regex (-E) mode as the default.
Package egrep implements the `egrep` built-in — grep with the extended-regex (-E) mode as the default.
Package env implements the `env` built-in.
Package env implements the `env` built-in.
Package eval implements the `eval` shell built-in.
Package eval implements the `eval` shell built-in.
Package exit implements the `exit` shell built-in.
Package exit implements the `exit` shell built-in.
Package expand implements the `expand` built-in.
Package expand implements the `expand` built-in.
Package export implements the `export` shell built-in.
Package export implements the `export` shell built-in.
Package expr implements the `expr` built-in.
Package expr implements the `expr` built-in.
Package falsecmd implements the `false` built-in.
Package falsecmd implements the `false` built-in.
Package fgrep implements the `fgrep` built-in — grep with the fixed-string (-F) mode as the default.
Package fgrep implements the `fgrep` built-in — grep with the fixed-string (-F) mode as the default.
Package file implements the `file` built-in.
Package file implements the `file` built-in.
Package find implements the `find` built-in.
Package find implements the `find` built-in.
Package fold implements the `fold` built-in.
Package fold implements the `fold` built-in.
Package getopts implements the `getopts` shell built-in.
Package getopts implements the `getopts` shell built-in.
Package grep implements the `grep`, `egrep`, and `fgrep` built-ins.
Package grep implements the `grep`, `egrep`, and `fgrep` built-ins.
Package gunzip implements the `gunzip` built-in — gzip with the decompress mode as the default.
Package gunzip implements the `gunzip` built-in — gzip with the decompress mode as the default.
Package gzip implements the `gzip`, `gunzip`, and `zcat` built-ins.
Package gzip implements the `gzip`, `gunzip`, and `zcat` built-ins.
Package hash implements the `hash` shell built-in.
Package hash implements the `hash` shell built-in.
Package head implements the `head` built-in.
Package head implements the `head` built-in.
Package help implements the `help` built-in.
Package help implements the `help` built-in.
Package history implements the `history` built-in.
Package history implements the `history` built-in.
Package hostname implements the `hostname` built-in.
Package hostname implements the `hostname` built-in.
Package htmltomarkdown implements the `html-to-markdown` built-in.
Package htmltomarkdown implements the `html-to-markdown` built-in.
Package jobs implements the `jobs` shell built-in.
Package jobs implements the `jobs` shell built-in.
Package join implements the `join` built-in.
Package join implements the `join` built-in.
Package jq implements the `jq` built-in.
Package jq implements the `jq` built-in.
Package let implements the `let` shell built-in.
Package let implements the `let` shell built-in.
Package ln implements the `ln` built-in.
Package ln implements the `ln` built-in.
Package local implements the `local` shell built-in.
Package local implements the `local` shell built-in.
Package ls implements the `ls` built-in.
Package ls implements the `ls` built-in.
Package mapfile implements the `mapfile` / `readarray` shell built-ins.
Package mapfile implements the `mapfile` / `readarray` shell built-ins.
Package md5sum implements the `md5sum` built-in.
Package md5sum implements the `md5sum` built-in.
Package mkdir implements the `mkdir` built-in.
Package mkdir implements the `mkdir` built-in.
Package mktemp creates private temporary entries exclusively in the VFS.
Package mktemp creates private temporary entries exclusively in the VFS.
Package mv implements the `mv` built-in.
Package mv implements the `mv` built-in.
Package nl implements the `nl` built-in.
Package nl implements the `nl` built-in.
Package od implements the `od` built-in.
Package od implements the `od` built-in.
Package paste implements the `paste` built-in.
Package paste implements the `paste` built-in.
Package popd implements the `popd` shell built-in.
Package popd implements the `popd` shell built-in.
Package printenv implements the `printenv` built-in.
Package printenv implements the `printenv` built-in.
Package printf implements the `printf` built-in (/ §10.18 details).
Package printf implements the `printf` built-in (/ §10.18 details).
Package pushd implements the `pushd` shell built-in.
Package pushd implements the `pushd` shell built-in.
Package pwd implements the `pwd` built-in.
Package pwd implements the `pwd` built-in.
Package read implements the `read` shell built-in.
Package read implements the `read` shell built-in.
Package readlink implements the `readlink` built-in.
Package readlink implements the `readlink` built-in.
Package readonly implements the `readonly` shell built-in.
Package readonly implements the `readonly` shell built-in.
Package returncmd implements the `return` shell built-in.
Package returncmd implements the `return` shell built-in.
Package rev implements the `rev` built-in.
Package rev implements the `rev` built-in.
Package rg implements the `rg` (ripgrep) built-in subset (/ Wave D).
Package rg implements the `rg` (ripgrep) built-in subset (/ Wave D).
Package rm implements the `rm` built-in.
Package rm implements the `rm` built-in.
Package rmdir implements the `rmdir` built-in.
Package rmdir implements the `rmdir` built-in.
Package sed implements the `sed` built-in.
Package sed implements the `sed` built-in.
Package seq implements the `seq` built-in.
Package seq implements the `seq` built-in.
Package set implements the `set` shell built-in.
Package set implements the `set` shell built-in.
Package sh implements the `sh` built-in — a thin shim around the `bash` built-in.
Package sh implements the `sh` built-in — a thin shim around the `bash` built-in.
Package sha1sum implements the `sha1sum` built-in.
Package sha1sum implements the `sha1sum` built-in.
Package sha256sum implements the `sha256sum` built-in.
Package sha256sum implements the `sha256sum` built-in.
Package shopt implements the `shopt` shell built-in.
Package shopt implements the `shopt` shell built-in.
Package sleep implements the `sleep` built-in.
Package sleep implements the `sleep` built-in.
Package sort implements the `sort` built-in.
Package sort implements the `sort` built-in.
Package source implements the `source` and `.` shell built-ins.
Package source implements the `source` and `.` shell built-ins.
Package split implements the `split` built-in.
Package split implements the `split` built-in.
Package sqlite3 registers a stub `sqlite3` built-in (// §14).
Package sqlite3 registers a stub `sqlite3` built-in (// §14).
Package stat implements the `stat` built-in.
Package stat implements the `stat` built-in.
Package strings implements the `strings` built-in.
Package strings implements the `strings` built-in.
Package tac implements the `tac` built-in.
Package tac implements the `tac` built-in.
Package tail implements the `tail` built-in.
Package tail implements the `tail` built-in.
Package tar implements the `tar` built-in.
Package tar implements the `tar` built-in.
Package tee implements the `tee` built-in.
Package tee implements the `tee` built-in.
Package test implements the `[` and `test` shell built-ins.
Package test implements the `[` and `test` shell built-ins.
Package time implements the `time` built-in.
Package time implements the `time` built-in.
Package timeout implements the `timeout` built-in.
Package timeout implements the `timeout` built-in.
Package touch implements the `touch` built-in.
Package touch implements the `touch` built-in.
Package tr implements the `tr` built-in.
Package tr implements the `tr` built-in.
Package trap implements the `trap` shell built-in.
Package trap implements the `trap` shell built-in.
Package tree implements the `tree` built-in.
Package tree implements the `tree` built-in.
Package truecmd implements the `true` built-in.
Package truecmd implements the `true` built-in.
Package umask implements the `umask` shell built-in.
Package umask implements the `umask` shell built-in.
Package unalias implements the `unalias` built-in.
Package unalias implements the `unalias` built-in.
Package unexpand implements the `unexpand` built-in.
Package unexpand implements the `unexpand` built-in.
Package uniq implements the `uniq` built-in.
Package uniq implements the `uniq` built-in.
Package unset implements the `unset` shell built-in.
Package unset implements the `unset` shell built-in.
Package wait implements the `wait` shell built-in.
Package wait implements the `wait` shell built-in.
Package wc implements the `wc` built-in.
Package wc implements the `wc` built-in.
Package which implements the `which` built-in.
Package which implements the `which` built-in.
Package whoami implements the `whoami` built-in.
Package whoami implements the `whoami` built-in.
Package xan implements the `xan` CSV toolkit built-in.
Package xan implements the `xan` CSV toolkit built-in.
Package xargs implements the `xargs` built-in.
Package xargs implements the `xargs` built-in.
Package yes implements the sandbox's finite, bounded yes stream.
Package yes implements the sandbox's finite, bounded yes stream.
Package yq implements the `yq` data-format swiss-army built-in.
Package yq implements the `yq` data-format swiss-army built-in.
Package zcat implements the `zcat` built-in — `gunzip -c` shorthand.
Package zcat implements the `zcat` built-in — `gunzip -c` shorthand.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL