TrashOS Reborn
TrashOS Reborn is a Python-based pseudo-operating-system that runs as a single script (boot.py) on top of a real host OS. It boots into an interactive shell, manages users, and runs apps from the tosapps/ directory. The tos library is the public API those apps use.
Version
- TrashOS Reborn
1.1.0 - Bootloader: TrashLoader
1.0.2 - Security patch:
SUBPRCSPTCH
Boot sequence
- POST.
- Detect CPU/GPU via
wmic(falls back to generic strings off-Windows). - Load the kernel image
trosreb.bininto RAMDISK. - Load CPU, GPU, fan-control drivers.
- Load
bash. - Prompt for username/password.
Built-in shell commands
| Command | Description |
|---|---|
help | List all commands. |
root | Enter root shell (password: root). |
ver | Print TrashOS version info. |
browser | Open the system web browser at google.com. |
calc | Launch calculator.py. |
hostos | Print the underlying host OS. |
echo | Echo a line of text. |
apps | List apps installed in tosapps/. |
usrmgr | User manager (add, change credentials). |
ls / mkdir / rmdir / rm / touch | Basic filesystem ops. Most are guarded for non-root users. |
changelog | Print recent changes. |
logout | Return to the login prompt. |
shutdown | Power off (exits the Python process). |
App resolution
Any unknown command is treated as an app name. The shell looks up tosapps/<name>.py and runs it with the current Python interpreter:
subprocess.run([sys.executable, app_exec])
If no file matches, difflib.get_close_matches is used to suggest the closest existing command.
Users
Accounts are stored in users.json. The defaults shipped with the system are root (password root), trash, and sys.
Warning: Passwords are stored in plain text. Treat users.json as sensitive.
Relationship to tos
Apps under tosapps/ are expected to import tos for filesystem layout (tos.appdata) and to honour root mode via tos.is_root(). The shell is expected to export TOS_ROOT_ACTIVE=TRUE when a root shell is active.