MMotor OS
Userspace

Commands

Motor OS boots into rush, a POSIX-style shell. PATH is /system/bin:/user/bin, plus /devtools/bin on the developer image. ls /system/bin and ls /user/bin list what is installed.

sysbox

Most everyday commands are calls into /system/bin/sysbox, which was inspired by busybox in Linux. Motor OS has no symbolic links, so each command is a two-line rush script of the same name in /system/bin that forwards to sysbox; sysbox help lists them.

CommandWhat it does
cat, less, wcPrint, page, and count files. less is a full pager built on the crossterm port.
ls, findList and search directories.
cp, mv, rm, mkdir, rmdirCopy (preserving permissions), move, and delete files and directories. A denied operation fails with a nonzero status.
chmod MODE PATH...Set permissions; MODE is nine characters in System, Interactive, None order (see Filesystem).
ps, pstat, top, free, uptime, statsProcesses (with role markers * System and + Interactive), CPU usage, memory, and any metric (see Logs and diagnostics).
ssTCP sockets known to sys-io.
ping [-c COUNT] [-i SECONDS] [-W SECONDS] [-s BYTES] DESTINATIONICMP echo to an IPv4 or IPv6 address, localhost, or a DNS name.
date, time, sleepThe current time, timing a command, and pausing.
printenvThe environment.
loopRun a command repeatedly.

A few names in /system/bin are scripts without a sysbox applet behind them: df (over stats), uname (prints "Motor OS"), sh (forwards to rush, so C library system() and popen() work), and exit (so that ssh host exit 5, which looks for an executable, works). kill, cd, history, clear, and the other shell builtins are part of rush. rg is ripgrep, a real binary, on the standard and developer images.

Programs

ProgramWhereWhat it is
rush/system/binThe shell, on the console and over SSH.
rmux/user/binA tmux-like terminal multiplexer with detachable sessions.
red/user/binA vi-like editor with syntax highlighting.
kibim/user/binA small kilo-style editor; standard and developer images.
httpd/user/binA small static-file HTTP server with optional TLS: httpd -a ADDR:PORT -d DIR [--ssl-cert PEM --ssl-key PEM].
httpd-axum/user/binThe same job on axum, tower-http, and Tokio, with TLS through rustls. Serves this website.
russhd/system/servicesThe SSH server; started by sys-init (see Running Motor OS).
curl/system/binDeveloper image: a small curl-compatible HTTPS client written in Rust, used by Lorry to fetch crates.
lua/devtools/binDeveloper image: Lua 5.4, built natively against the C library.

The developer image adds Lorry, Gears, mdbg, the native compilers, and the test suites; see Developer image.

Configuration files

FileUsed by
/system/cfg/sys-init.cfgsys-init: the console program and role, strobe, and the services with their capability masks.
/system/cfg/sys-net.tomlsys-io: network devices, addresses, routes, DNS servers, and limits.
/system/cfg/sshd.tomlrusshd: listen address, host key, users, passwords, and authorized keys.
/system/cfg/sys-tty.cfg, /system/cfg/rush.cfgThe console shell's environment and startup file.
/system/cfg/libc/hosts, resolv.confThe DNS resolver and the C library. resolv.conf is written by sys-io.
/user/cfg/red.toml, rmux.toml, kibim/, gears.toml, lorry/Per-program settings, all optional.