toyboxAbout
|
Current release 0.8.11 (April 8, 2024)Toybox is a single executable implementing over two hundred different Linux command line utilities. By default it uses its filename to determine which command to run, so it can be installed with symlinks like "ln -s toybox sed" to put all the commands into the search $PATH. The special name "toybox" uses its first argument as the command to run, ala "toybox df -a", so you can use it without installing it. Running "toybox" with no arguments lists the available commands. Each toybox command has built-in documentation, which you can read in three different ways:
You can download a toybox binary and try it out like so:
Installing toybox into the $PATH looks something like:
To compile toybox from source:
Toybox's build has "make menuconfig" like the kernel (and the usual targets: clean, distclean, allnoconfig...), run "make help" to list more options. The binaries distributed on the website are statically linked against musl-libc to provide a portable executable without external userspace dependencies. To reproduce that:
You can also build individual toybox commands as standalone executables, either by name ("make sed") or using the "make change" target (as in change for a $20) to build all of them at once. This is much less efficient than the default build, the individual commands add up to around ten times the size of the equivalent all-in-one toybox binary. |