allbctl
allbctl is short for allbrightctl: a command line interface for the computer
operations that I (Andrew Allbright) do. It inspects a developer machine
(status), brings a fresh one up to my baseline (bootstrap) and updates its
package managers (update). It runs on Linux, macOS, WSL and Windows.
Full documentation: installation,
every command, and the JSON output contract.
Install
macOS / Linux via Homebrew:
brew install aallbrig/tap/allbctl
Debian / Ubuntu via APT:
curl -fsSL https://aallbrig.github.io/apt-repo/KEY.gpg | sudo gpg --dearmor -o /usr/share/keyrings/allbctl.gpg
echo "deb [signed-by=/usr/share/keyrings/allbctl.gpg] https://aallbrig.github.io/apt-repo stable main" | sudo tee /etc/apt/sources.list.d/allbctl.list
sudo apt update && sudo apt install allbctl
Windows via Chocolatey:
choco install allbctl
The Chocolatey community repository moderates every version by hand, so the
version it offers can lag behind the latest release. Use a release archive
when you need the newest one.
Container image (GitHub Container Registry, tagged per release and latest):
docker run --rm ghcr.io/aallbrig/allbctl:latest version
A container only sees itself. To report on the host it runs on, share the
host's namespaces and mount its files read-only:
docker run --rm --pid=host --net=host \
-v /proc:/proc:ro -v /sys:/sys:ro -v /etc:/etc:ro -v "$HOME:$HOME:ro" \
ghcr.io/aallbrig/allbctl:latest status
Release archives. Every release
has one archive per platform, a SHA256SUMS file and signed build provenance:
| Platform |
Archive |
Binary inside |
| Linux x86-64 / arm64 |
allbctl-linux-amd64.tar.gz, allbctl-linux-arm64.tar.gz |
allbctl_linux_<arch> |
| macOS Intel / Apple Silicon |
allbctl-darwin-amd64.tar.gz, allbctl-darwin-arm64.tar.gz |
allbctl_darwin_<arch> |
| Windows x86-64 / arm64 |
allbctl-windows-amd64.zip, allbctl-windows-arm64.zip |
allbctl_windows_<arch>.exe |
curl -LO https://github.com/aallbrig/allbctl/releases/latest/download/allbctl-linux-amd64.tar.gz
gh attestation verify allbctl-linux-amd64.tar.gz --repo aallbrig/allbctl # optional: check provenance
tar -xzf allbctl-linux-amd64.tar.gz
sudo install allbctl_linux_amd64 /usr/local/bin/allbctl
allbctl version
From source (needs the Go version named in go.mod and Task):
task build # bin/allbctl, with version info embedded
task install # go install, with version info embedded
Commands
allbctl --help
# The whole machine at a glance
allbctl status
# One section at a time
allbctl status runtimes # languages with versions and available updates
allbctl status projects # git repositories under ~/src, most recent first
allbctl status projects --dirty # only repos with uncommitted or unpushed work
allbctl status projects --clean # only repos with nothing outstanding
allbctl status projects --limit 5 -v # five repos, with changed files, CI checks and languages
allbctl status list-packages # package count per package manager
allbctl status list-packages --detail # every package of every manager
allbctl status list-packages npm # one manager's packages and the command that lists them
allbctl status db # detected databases
allbctl status db sqlite3 --detail # one database: binaries, files under ~/src, environment
allbctl status network # interfaces, gateway, DNS, VPN, connectivity, public IP
allbctl status ports # listening TCP/UDP sockets and their processes
allbctl status containers # Docker / Podman usage, virtualization
allbctl status security # SSH agent keys, GPG keys, kernel keyring (Linux)
allbctl status systemctl # running and failed systemd services (Linux)
allbctl status git # global git user.name, user.email, core.editor
allbctl status cloud-native # aws, gcloud, az, kubectl: version, profiles, connectivity
allbctl status cn aws --profile dev --region us-east-1 # AWS resource counts by region
# Bring a machine up to the baseline (alias: bs)
allbctl bootstrap status # a check: exits 1 while something is missing
allbctl bootstrap install # apply what is missing
allbctl bootstrap install --register-ssh-keys
allbctl bootstrap reset # undo what can safely be undone
# Update every detected package manager (aliases: up, upgrade)
allbctl update --dry-run # show the commands without running them
allbctl update --managers brew,npm
# Machine-readable output and its schemas
allbctl status ports --output json
allbctl schema StatusPorts
allbctl version
allbctl completion zsh # also bash, fish, powershell
Global flags: --config <file> (default $HOME/.allbctl.yaml) and --debug
(structured logs, traces and metrics on stderr).
allbctl status
Every section is gathered at the same time and printed in a fixed order as
soon as it and the sections before it are ready. Lines with nothing to report
(for example Runtimes, Databases or Browsers on a machine that has none) are
left out.
Most of what status reports is learned by running other tools, and most of
those answers only change when the tool, or what it reports on, changes. They
are therefore cached in the user cache directory
($XDG_CACHE_HOME/allbctl/updates, or the operating system's default), each
under a fingerprint of what it depends on and for a limited time:
| Answer |
Served from the cache until |
Version of a tool (--version) |
the tool's executable changes (path, size or modification time), a version pin file in the working directory changes (go.mod, rust-toolchain, .tool-versions, …), or 6 hours pass. Launchers of version managers (…/shims/…) are always asked. |
| Package count of a manager |
the manager's record of installed packages changes (Homebrew's Cellar/Caskroom, npm's global node_modules, pip's site-packages, ~/.cargo/.crates.toml, …) or 6 hours pass; 10 minutes for a manager without such a record. ollama and go are always asked. |
| Outdated packages of a manager |
6 hours pass, or allbctl update runs that manager |
| Newest upstream release of a tool |
24 hours pass |
| CI status of a repository's branch (one GitHub API call each) |
the branch gets a new commit or 10 minutes pass; a failed look-up is remembered just as long, and once one look-up times out (5 seconds) the remaining repositories of that run are not asked |
| A repository's remote |
its or your git configuration changes, or 24 hours pass |
"AWS accepts this profile's credentials" (aws sts get-caller-identity) |
the AWS configuration or the single sign-on cache changes or 1 hour passes; "not connected" for 10 minutes |
"kubectl reaches a cluster" (kubectl cluster-info) |
the kubeconfig changes or 10 minutes pass |
GPUs of a Mac (system_profiler) |
the machine restarts or 7 days pass |
A check that failed is asked again after an hour at the latest. The cache
never holds a credential or an account identifier: of a network call made
with your credentials only what status prints is kept (whether it
succeeded; the name and conclusion of a check run). Everything else — the
state of every repository's working tree, listening ports, running servers,
disks, memory, the network — is asked for on every run.
--refresh ignores the cache and asks everything again; --debug shows, per
answer, whether it came from the cache and how old it was (update-cache.hit
/ update-cache.miss), and how long every section took (status.section).
dev@dev-laptop
allbctl v0.0.43 (commit abc1234)
OS: ubuntu 24.04
Hostname: dev-laptop
Shell: /usr/bin/zsh
Terminal: tmux
CPU:
Model: 13th Gen Intel(R) Core(TM) i7-1360P
Arch: x86_64
Clock: 5.00 GHz
Cores: 12 physical, 16 logical (2 threads/core)
GPU(s):
Name: NVIDIA RTX A500 Laptop GPU
Vendor: NVIDIA
Memory: 4096 MiB
Memory: 31.2 GiB
Disks: 2 total (1383.7 GiB)
Mount: /
Device: /dev/nvme0n1p2
Type: ext4
Size: 467.9 GiB total
Used: 211.3 GiB (45.2%)
Free: 256.6 GiB
Mount: /home
Device: /dev/sda1
Type: ext4
Size: 915.8 GiB total
Used: 402.1 GiB (43.9%)
Free: 513.7 GiB
Hardware: Dell Inc. XPS 13 9310
Runtimes: Python (3.12.3), Node.js (22.11.0 → 24.11.1 (LTS)), Go (1.25.5)
Databases: sqlite3 (3.45.1), postgres (16.6) [running]
Network:
Primary Interface: wlp0s20f3 (192.0.2.10/24)
WiFi: example-wifi @ 5.24 GHz (802.11ac/ax)
Speed: 866.7 Mbps | Signal: -56 dBm (Good)
Gateway: 192.0.2.1
DNS:
System: 192.0.2.1
Connectivity:
Public IP: 203.0.113.10
Internet: ✓ Connected
Other Interfaces:
lo: 127.0.0.1/8
docker0: 172.17.0.1/16
Ports: 24 listening (TCP: 18, UDP: 6)
Browsers:
Chromium (145.0.7632.45), Firefox (147.0.3)
AI Agents:
copilot (0.0.365), claude (2.0.76)
Package Managers:
System: apt (2.8.3), flatpak (1.14.6)
Language: nvm (0.40.3)
Runtime: npm (11.6.2 → 11.7.0), pip (24.0), go (1.25.5)
Packages:
dpkg: 2166 packages
apt: 1991 packages (34 want updates)
npm: 10 packages (5 want updates)
pip: 110 packages
Cloud Native:
aws (2.33.1) - 1 profile ✓
kubectl (1.34.2) [kustomize: 5.7.1] - 0 contexts ✗
Projects: 12 total (7 dirty)
Last 5 recently touched:
~/src/allbctl* dev/allbctl 2026-03-07 16:19 EST -0500 [uncommitted changes]
~/src/dotfiles dev/dotfiles 2026-03-07 11:40 EST -0500 ✓
~/src/notes* dev/notes 2026-03-06 15:41 EST -0500 [unpushed commits]
~/src/scratch* - 2026-03-05 14:49 EST -0500 [uncommitted changes, no upstream]
~/src/website dev/website 2026-03-04 14:30 EST -0500
What the sections mean:
- Memory and disk sizes are binary units (GiB, MiB). Memory is what the
operating system sees: for example
31.2 GiB on a 32 GB machine.
- Disks lists each physical store once, at its most meaningful mount.
Virtual filesystems, snap and loop images, bind mounts of a store already
listed, and the volumes macOS keeps for itself are not disks: an Apple
Silicon Mac shows its APFS container once, at
/. In a container, files
bind-mounted from the host (/etc/hosts, /etc/resolv.conf) are not listed
either.
- CPU adds
P-cores / E-cores on Apple Silicon and a Layout line on
multi-socket machines. GPU details come from nvidia-smi when it is
installed, otherwise from lspci (Linux), system_profiler (macOS) or
PowerShell CIM queries (Windows).
- Runtimes, Databases, AI Agents, Package Managers show
current → newer
when a newer release is known, with (LTS) for Node.js and Java.
- Network: the gateway is the default gateway, the IPv4 one when the
interface has both.
VPN Active appears
when a tunnel interface (tun*, tap*, wg*, ppp*, vpn*) is up. The
public IP is looked up with curl, and the connectivity check is a TCP
connection to a public DNS server.
- Packages counts explicitly installed system packages and globally
installed language packages, with
(N want updates) when updates are
pending. allbctl status list-packages prints the same counts without the
update hints, because the update check is the slow part.
- Projects are the git repositories under
~/src. * marks a dirty
repo and the labels say why: uncommitted changes, unpushed commits,
no upstream, ci failed or ci pending. ✓ means its CI checks passed.
Sections that have their own subcommand but are not part of allbctl status:
containers, security, systemctl and git.
A subcommand asked about a tool that is absent says so in one line and exits
0, because that is the status that was asked for:
$ allbctl status git
git: not installed
$ allbctl status systemctl
systemctl: not available on macOS
What is detected
- Languages: Python, Node.js, Go, Java, Ruby, Rust, PHP, Perl, R, Scala,
Kotlin, Swift, Elixir, Erlang, Haskell, Lua, Dart, Zig, C#.
- Version managers: nvm, pyenv, rbenv, jenv, rustup, asdf, SDKMAN.
- Databases: SQLite, MySQL, MariaDB, PostgreSQL, MongoDB, Redis,
Cassandra, Oracle, SQL Server.
- Browsers: Chrome, Chromium, Firefox, Edge, Safari, Brave, Opera, Vivaldi.
- AI agents:
copilot, claude, cursor, aider, continue, cody,
tabby, codewhisperer, ollama.
- Cloud CLIs:
aws, gcloud, az, kubectl.
- Package managers:
| Package manager |
Linux |
macOS |
Windows |
Counts |
dpkg, rpm, apt, snap, flatpak, dnf, yum, pacman |
✅ |
❌ |
❌ |
packages |
brew |
✅ |
✅ |
❌ |
packages |
choco, winget, scoop |
❌ |
❌ |
✅ |
packages |
npm, pip, pipx, gem, cargo, go |
✅ |
✅ |
✅ |
global packages |
ollama |
✅ |
✅ |
✅ |
models |
vagrant, vboxmanage |
✅ |
✅ |
✅ |
VMs |
allbctl status list-packages <manager> also prints the command it ran
(for example Command: apt-mark showmanual), and with --detail the five
most recently installed packages where the manager can tell.
allbctl bootstrap
bootstrap describes the baseline of a workstation and checks or applies it:
- the directories
~/src (and ~/bin on macOS);
git and the GitHub CLI gh, installed with the platform's package
manager (apt, dnf, yum, pacman, zypper or apk on Linux; Homebrew on macOS;
winget, Chocolatey or Scoop on Windows). The package manager is not run
through sudo, so on Linux installing them needs root;
- an SSH key registered with GitHub (applied only with
--register-ssh-keys, which needs gh auth login first);
- on macOS, a
GITHUB_TOKEN environment variable (checked, never set);
- the dotfiles repository cloned to
~/src/dotfiles and its ./fresh.sh
install script run;
- the tools that the shell configuration files (
.zshrc, .bashrc,
.bash_profile, .profile) refer to, reported as INSTALLED or MISSING.
allbctl bootstrap status || allbctl bootstrap install
bootstrap status changes nothing. It is a check: it exits 0 only when
everything is in place, and otherwise lists what is missing on stderr and
exits 1. bootstrap install attempts every step even when an earlier one
fails, and is safe to run again.
bootstrap reset undoes what can be undone safely. A directory that still has
contents (for example ~/src) is never deleted: it is reported as
left untouched (not empty). That is the safety working, not a failure, so it
does not affect the exit code. Tools, the SSH key registration and the
dotfiles are left for you to remove by hand. Any other step that cannot be
undone is listed on stderr and the command exits 1.
allbctl update
Runs the update and upgrade commands of every detected package manager, one
after another: apt, flatpak, snap, dnf, yum, pacman, brew, choco, winget, npm,
pipx and gem. pip, cargo and go are skipped on purpose. --dry-run prints the
commands without running anything; --managers apt,npm limits the run. A
manager that fails does not stop the others.
Exit Codes
Scripts can rely on allbctl's exit code:
| Code |
Meaning |
0 |
Success. |
1 |
The command ran and failed, or a check did not pass. |
2 |
Usage error: unknown command, flag or argument, or an invalid flag value. Nothing was attempted. |
130 |
Interrupted by SIGINT (Ctrl-C) or SIGTERM. |
Command output goes to stdout. Errors and diagnostics go to stderr, an error is
reported exactly once, and usage is only shown for usage errors.
What counts as a failure (1):
allbctl update — any package manager failed to update. The remaining
managers are still attempted and a summary of which succeeded, failed and
were skipped is printed. A manager named in --managers that is supported
but not installed on this machine is skipped, which is not a failure;
--dry-run executes nothing and so never fails for this reason.
allbctl bootstrap status — the machine is not fully configured.
allbctl bootstrap install / allbctl bootstrap reset — any step failed;
the failed steps are listed.
allbctl status db <database> / allbctl status list-packages <manager> /
allbctl status cloud-native aws --profile <name> —
the database, package manager or AWS profile asked for is not present on
this machine.
What counts as a usage error (2), in addition to unknown commands and flags:
extra positional arguments, an unknown name for update --managers,
status db or status list-packages, combining --all, --dirty and
--clean on status projects, a negative --limit, an --output other than
text or json, and a --config file that does not exist.
Scripting / JSON output
Every command that reports on the machine — status and all of its
subcommands, version and bootstrap status — takes -o, --output text|json.
With --output json, stdout is exactly one JSON document followed by a
newline; errors still go to stderr and the exit codes above still apply.
allbctl status ports --output json
{
"apiVersion": "allbctl/v1",
"kind": "StatusPorts",
"generatedAt": "2026-01-02T03:04:05Z",
"allbctlVersion": "1.2.3",
"host": { "os": "linux", "arch": "amd64" },
"data": {
"tcpCount": 1,
"udpCount": 0,
"totalCount": 1,
"listeners": [
{ "protocol": "tcp", "address": "0.0.0.0", "port": 22, "process": "sshd", "pid": 812 }
]
}
}
The envelope (apiVersion, kind, generatedAt, allbctlVersion, host,
data) is the same for every command; kind says what data holds. Fields
are always present: what is unknown is null, a tool that is absent has
"installed": false, and arrays are never null. Credentials are redacted
exactly as in the text output.
# TCP ports something is listening on
allbctl status ports -o json | jq '.data.listeners[] | select(.protocol == "tcp") | .port'
# Runtimes with a newer release available
allbctl status runtimes -o json | jq -r '.data.runtimes[] | select(.update != null) | .name'
# Repositories with uncommitted or unpushed work
allbctl status projects --dirty -o json | jq -r '.data.repositories[].path'
# What bootstrap would still have to do
allbctl bootstrap status -o json | jq -r '.data.sections[].notInPlace[].step'
Each kind of document has a JSON Schema (draft 2020-12), shipped in the binary
and published with the docs site under
https://aallbrig.github.io/allbctl/schemas/v1/:
allbctl schema # list the kinds
allbctl schema StatusPorts # one kind's schema
allbctl schema --all # every schema as one self-contained bundle
Within apiVersion: allbctl/v1 changes are additive only; a breaking change
gets a new apiVersion. See the "JSON Output" page of the docs for the list
of kinds, the conventions and the stability policy.
Development
Task is the single entry point; the
Makefile only forwards to it. CONTRIBUTING.md has the full gate table.
task tools:install # pinned golangci-lint, govulncheck, gitleaks, actionlint
task setup # install the git hooks, check the toolchain
task build # bin/allbctl
task test:short # fast unit tests; skips the ones that probe this machine
task test # every test, with the race detector
task ci # every gate CI runs, in order
task dev # tmux session with one live pane per gate (tmuxinator)
- Git hooks (
task setup): pre-commit checks the staged files (secrets,
formatting, strict lint, go mod tidy), commit-msg enforces Conventional
Commits and pre-push runs task ci:fast.
task dev starts the tmuxinator session in .tmuxinator/allbctl.yml:
a local Grafana LGTM stack for telemetry and a watchers window that
re-runs each gate as files change. It needs tmux, tmuxinator, watchexec and
Docker, and runs on macOS, Linux and WSL.
- Docs: the CLI reference pages and the published schemas are generated
(
task gen-docs, task gen-schemas); task docs-check fails when they are
stale.
Windows VM testing
task vagrant-test-windows # boot the Windows 10 Vagrant VM and run the smoke tests
See test/windows-vm-test.md for the manual steps.
Contributing
Please reference the CONTRIBUTING.md file.