Skip to content

Packages (Linux): adds soar system-wide package detection - #2763

Open
QaidVoid wants to merge 1 commit into
fastfetch-cli:devfrom
pkgforge-dev:soar-system
Open

QaidVoid wants to merge 1 commit into
fastfetch-cli:devfrom
pkgforge-dev:soar-system

Conversation

@QaidVoid

Copy link
Copy Markdown
Contributor

Splits soar into soar-user and soar-system, and honors SOAR_DB, SOAR_ROOT and XDG_DATA_HOME for user packages.

Summary

Adds detection of system-wide soar packages and updates user package detection for current soar versions.

Changes

  • Detects system-wide soar packages from /opt/soar/db/soar.db.
  • Resolves the user database the way soar does: $SOAR_DB, then $SOAR_ROOT/db, then $XDG_DATA_HOME/soar/db (falling back to ~/.local/share/soar/db).
  • Counts all rows in the packages table. Recent soar versions allow a NULL pkg_id, so the old COUNT(DISTINCT pkg_id || pkg_name) silently skipped those packages. The is_installed filter is dropped because soar will remove that column in future.
  • Splits the count into soar-user and soar-system.

Breaking: the {soar} format arg is replaced by {soar-user}, {soar-system} and {soar-all}. The JSON key soar is replaced by soarUser and soarSystem. Numeric format args after {snap} shift by one.

Checklist

  • I have tested my changes locally.

Splits `soar` into `soar-user` and `soar-system`, and honors
`SOAR_DB`, `SOAR_ROOT` and `XDG_DATA_HOME` for user packages.

This branch has not been deployed

No deployments
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.

1 participant