Skip to content

Add GPT autodiscovery advisory to status output - #34

Merged
GlitchSlayed merged 1 commit into
mainfrom
codex/add-gpt-autodiscovery-awareness-check
Mar 19, 2026
Merged

GlitchSlayed merged 1 commit into
mainfrom
codex/add-gpt-autodiscovery-awareness-check

Conversation

@GlitchSlayed

Copy link
Copy Markdown
Owner

Motivation

  • Make rustyuki status aware of Discoverable Partitions Specification (DPS) so users get a helpful advisory when their root partition already carries a discoverable GPT type GUID.
  • Avoid silently baking redundant or fragile root= cmdline tokens into UKIs by providing advisory (not automatic) guidance to remove them when GPT autodiscovery will work.

Description

  • Implemented discoverable_root_advisory in src/app.rs which reads the configured cmdline file, checks for a root= token, reads /proc/mounts to find the device mounted at /, and queries lsblk -no PARTTYPE for that device to obtain the partition GPT type GUID.
  • Added dps_root_guid mapping for architecture-specific DPS root GUIDs and parse_root_mount_source helper to extract / mount source.
  • Added discoverable_root_message to format the two advisory outputs: an [INFO] advisory when root= is present and the partition GUID matches DPS, and an [OK] confirmation when root= is absent and the GUID matches; the code emits no automatic changes to the cmdline file.
  • Updated tests and added unit coverage for root mount parsing, DPS GUID lookup, and both advisory message paths, and adjusted the status integration test to use a temporary cmdline file; changes are all in src/app.rs and test updates in tests/integration_cli.rs.

Testing

  • Ran formatting with cargo fmt --all which completed successfully.
  • Ran the full test suite with cargo test which completed successfully; all unit and integration tests passed.
  • Existing status/integration tests were updated to exercise the new advisory behavior and the new unit tests cover the parsing and message logic.

Codex Task

@GlitchSlayed
GlitchSlayed merged commit a26ece4 into main Mar 19, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant