Commit Graph

11 Commits

Author SHA1 Message Date
83d92be37a refactor(snack): merge GroupIsInstalled into Grouper interface
GroupQuerier was an unnecessary indirection — GroupIsInstalled is a group
operation and belongs on Grouper. No v1 stability guarantee, so breaking
the interface is fine.
2026-02-28 07:08:34 +00:00
bbb745434e Merge remote-tracking branch 'origin/copilot/add-isheld-method-to-holder-interface' into cd/integration-copilot-prs 2026-02-28 07:07:25 +00:00
c55027f9b7 merge: resolve pacman capabilities conflict (keep both interfaces) 2026-02-28 07:07:21 +00:00
copilot-swe-agent[bot]
22dda8684d Move GroupIsInstalled to separate GroupQuerier optional interface
Co-authored-by: taigrr <8261498+taigrr@users.noreply.github.com>
2026-02-28 06:54:28 +00:00
copilot-swe-agent[bot]
135e7c70f4 Add IsHeld method to Holder interface and implement in apt/dnf backends
Co-authored-by: taigrr <8261498+taigrr@users.noreply.github.com>
2026-02-28 06:24:07 +00:00
copilot-swe-agent[bot]
dec1516387 Add GroupIsInstalled to Grouper interface with pacman and dnf implementations
Co-authored-by: taigrr <8261498+taigrr@users.noreply.github.com>
2026-02-28 06:23:21 +00:00
copilot-swe-agent[bot]
9f943e9097 Add DryRunner interface and DryRun capability for dry-run support detection
Co-authored-by: taigrr <8261498+taigrr@users.noreply.github.com>
2026-02-28 06:22:26 +00:00
5b3517e5a8 fix(dnf): add dnf5 versionlock parser, relax test assertions
- Add parseVersionLockDNF5 for dnf5's 'Package name: <name>' format
- Wire v5 flag through listHeld
- Relax apt ListRepos (DEB822 format may yield empty)
- Relax snap Info version assertion (uninstalled snaps)
- Add unit test for parseVersionLockDNF5
2026-02-26 03:15:47 +00:00
f4b9679504 feat(dnf): fix dnf5 addRepo compatibility, expand test coverage
- Fix addRepo to use 'config-manager addrepo --from-repofile=' for dnf5
  (dnf4 uses 'config-manager --add-repo')
- Add fedora:latest (dnf5) to containertest matrix
- Add IsDNF5 detection integration test
- Add RepoManager and NameNormalizer integration test coverage
- Rename containertest fedora entry to fedora-dnf4 for clarity
2026-02-26 02:40:11 +00:00
beb4c51219 feat(dnf): add dnf5 compatibility
Detect dnf5 at startup via 'dnf --version' output and route to
version-specific parsers and command arguments.

Key changes:
- DNF struct caches v5 detection result
- New parse_dnf5.go with parsers for all dnf5 output formats
- stripPreamble() removes dnf5 repository loading noise
- Command arguments adjusted: --installed, --upgrades, --available
- CI matrix expanded with fedora:latest (dnf5) alongside fedora:39 (dnf4)
- Full backward compatibility with dnf4 preserved
2026-02-26 02:11:27 +00:00
2685dd945c feat: add dnf and rpm package manager implementations
Implements the dnf sub-package with Manager, VersionQuerier, Holder,
Cleaner, FileOwner, RepoManager, KeyManager, Grouper, and NameNormalizer
interfaces.

Implements the rpm sub-package with Manager, FileOwner, and
NameNormalizer interfaces.

Both follow the existing pattern: exported methods on struct delegate to
unexported functions, _linux.go for real implementations, _other.go with
build-tag stubs, embedded snack.Locker for mutating operations, and
compile-time interface checks.

Includes parser tests for all output formats.
2026-02-25 22:30:16 +00:00