Skip to content

app/db: Add --avail option to diff against available update#5561

Open
kairosci wants to merge 1 commit intocoreos:mainfrom
kairosci:db-diff-avail
Open

app/db: Add --avail option to diff against available update#5561
kairosci wants to merge 1 commit intocoreos:mainfrom
kairosci:db-diff-avail

Conversation

@kairosci
Copy link

@kairosci kairosci commented Feb 8, 2026

This PR adds a new --avail option to the rpm-ostree db diff command.

When the --avail option is used, the command identifies the latest available update cached on the system and performs a diff against it.

Usage examples:

  1. Diff booted deployment against the latest available update:

    rpm-ostree db diff --avail
  2. Diff a specific revision against the latest available update:

    rpm-ostree db diff --avail <FROM_REV>

Note: This requires a cached update to be present (usually via rpm-ostree upgrade --check).

Closes: #1953

Copy link

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request introduces the --avail option to rpm-ostree db diff, allowing users to compare a revision against the latest available update. The implementation correctly handles argument parsing, fetches the available update information via DBus, and determines the 'from' and 'to' revisions for the diff. The code is well-structured with good error handling. I have one suggestion regarding code duplication to improve long-term maintainability.

@kairosci kairosci force-pushed the db-diff-avail branch 2 times, most recently from 53249e0 to 013403d Compare February 11, 2026 09:05
@kairosci
Copy link
Author

@jmarrero PTAL, thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

how to diff latest local deployment with latest available updates?

1 participant