miniximg-cli
Command-line tool for building, inspecting, editing, and interactively exploring Minix v1 filesystem images.
miniximg-cli ships the miniximg binary. It glues
miniximg (the core library) and
miniximg-shell (the
interactive REPL) into a single tool.
At a glance
| Subcommand | One-liner |
|---|---|
build |
Create a new image from a TOML manifest or --entry flags. |
inspect |
Print a human-readable summary of an existing image. |
check |
Validate an image and exit non-zero on issues. |
ls, tree, cat, stat |
Read-only browsing. |
get, put |
Transfer one file between the host and an image. |
mkdir, mknod, rm, rmdir, mv, ln |
Direct mutating ops. |
shell |
Drop into an interactive REPL against the image. |
Run miniximg <subcommand> --help for the full set of flags on any one
command.
Build an image
From a TOML manifest:
Or with explicit mappings on the command line:
Manifest shape
build --manifest expects a TOML file with one [image] table and zero
or more [[mapping]] entries.
[]
= "build/rootfs.img"
= "4MiB"
= 128
= 0
= 0
= "0644"
= "0755"
[[]]
= "tree"
= "build/root"
= "/"
= true
[[]]
= "file"
= "README.md"
= "/etc/motd"
= true
[[]]
= "dir"
= "/var/log"
= "0755"
[[]]
= "char-device"
= "/dev/tty0"
= 4
= 0
= "0666"
Supported mapping kinds: file, tree, dir, block-device,
char-device.
Inspect and validate
Read-only browsing
Mutating operations
Interactive shell
For ad-hoc exploration and editing, shell is much faster than chaining
individual subcommands.
(rootfs.img) /> ls /etc
group hostname motd passwd profile rc
(rootfs.img) /> edit /etc/motd # opens $EDITOR, writes back on save
(rootfs.img) /> put @./local-fix.sh /usr/local/bin/fix
(rootfs.img) /> diff /etc/motd @./old-motd
See miniximg-shell for the
full command list, prompt syntax, and the @-prefix convention.
License
MIT. See LICENSE in the workspace root.