The low-level standalone engine and "Physics" layer of the ROMs ecosystem.
rmspkg is the heavy-lifting component responsible for the actual installation, extraction, and lifecycle management of applications. It is designed to be fully standalone, allowing users to manage packages even without the high-level roms manager.
This guide is for users who prefer using the low-level engine directly or are operating in a standalone environment.
Unlike most package managers, rmspkg does not require a remote registry to function. It can install any valid .rms package or project folder directly.
These flags work with all commands:
| Flag | Alias | Description |
|---|---|---|
-y |
--yes |
Skip confirmation prompts (AutoConfirm). |
-v |
--verbose |
Enable verbose debug logging. |
-vv |
Very verbose (shows TRACE messages). | |
-vvv |
Raw output (shows RAW messages). | |
-h |
--help |
Show help for the command. |
| Command | Description |
|---|---|
rmspkg <path> |
Install a local .rms file or project folder. |
rmspkg uninstall <name> |
Remove an installed package by its name. |
rmspkg bootstrap |
Install or repair the standalone engine to system root. |
rmspkg help |
Show the standalone help menu. |
- Logs: Every installation has its own dedicated log file at
C:\roms\logs\<package_name>.log. - Integrity Errors: If an installation fails,
rmspkgautomatically attempts an atomic rollback to leave your system clean. Check the logs for "ROLLBACK" messages. - Elevation Required: Most operations require Administrator privileges. Run PowerShell as Administrator.
- Missing Engine: If
rmspkgis not found in PATH, runrmspkg bootstrapto self-install.
# Install from local .rms file
rmspkg C:\Downloads\package-v1.0.0.rms
# Install from project folder
rmspkg C:\Projects\my-app
# Install with verbose output
rmspkg C:\Downloads\package-v1.0.0.rms -vvv
# Skip confirmation prompt
rmspkg C:\Downloads\package-v1.0.0.rms -y
# Uninstall a package
rmspkg uninstall my-package
# Repair/install engine to system root
rmspkg bootstrap
# Show help
rmspkg helpThis guide is for developers building packages or contributing to the engine core.
rmspkg handles the "Physics" of the ecosystem:
- Router:
rmspkg.ps1handles argument parsing and command routing. - Core:
lib/core.ps1manages global constants, colorized logging, and dependency checking. - Installer:
lib/installer.ps1handles the atomic installation lifecycle. - Uninstaller:
lib/uninstaller.ps1handles safe package removal. - Hooks:
lib/hooks.ps1manages lifecycle hooks (pre-install, post-install, etc.). - Environment:
lib/environment.ps1handles shim creation and PATH updates. - Bootstrap:
lib/bootstrap.ps1handles self-installation and engine recovery. - Help:
lib/help.ps1provides CLI help display.
The engine follows a strict Try/Catch/Rollback pattern:
- Validation: Checks system dependencies and manifest integrity using the Truth-Verification Watchdog.
- Extraction: Files are unpacked to the standardized application folder in
C:\roms. - Registration: Metadata and artifacts (like shims) are recorded.
- Hooks: System-level OS hooks are executed using the Hybrid Standard (Manifest-First or Fallback).
- Rollback: If any step above fails, the engine deletes the partial installation and unregisters the metadata.
rmspkg.ps1 (Router)
|
+---> lib/core.ps1 (Write-Log, Check-RomsDependencies, Confirm-Elevation)
|
+---> lib/installer.ps1 (Invoke-Installation, Find-PackageExecutables)
| |
| +---> lib/hooks.ps1 (Get-RomsHookPath, Invoke-RomsHook)
| +---> lib/environment.ps1 (Create-Shim, Update-EnvironmentPath)
|
+---> lib/uninstaller.ps1 (Invoke-Uninstallation)
| |
| +---> lib/hooks.ps1 (Get-RomsHookPath, Invoke-RomsHook)
|
+---> lib/bootstrap.ps1 (Invoke-SelfBootstrap)
|
+---> lib/help.ps1 (Show-Help)
| Variable | Description | Default |
|---|---|---|
ROMs_ROOT |
Ecosystem root directory | C:\roms |
ROMs_BIN |
Command shims directory | C:\roms\bin |
ROMs_METADATA |
Package metadata registry | C:\roms\.metadata |
ROMs_LOGS |
Log files directory | C:\roms\logs |
ROMs_TEMP |
Temporary workspace | C:\roms\temp |
To ensure version independence and maximum reliability, rmspkg avoids high-level PowerShell cmdlets for core tasks. It uses native .NET namespaces for:
- Hashing:
System.Security.Cryptography.SHA256 - Compression:
System.IO.Compression.ZipFile - File I/O:
System.IO.FileandSystem.IO.Directory
To create a package compatible with this engine, use the rms-builder tool. Ensure your roms_package.json follows the Trinity v1.1.0 standard.
- Add new functions to the appropriate module in
lib/. - Add comprehensive comments explaining HOW IT WORKS.
- Export the function from the main
rmspkg.ps1if it's a new command. - Test with
-vvvflag to verify RAW output logging. - Update this README if adding new commands or changing architecture.