Skip to content

dmcheck: check installed package names exactly - #116

Open
ranicharradi wants to merge 1 commit into
CachyOS:masterfrom
ranicharradi:fix/dmcheck-exact-package-checks
Open

ranicharradi wants to merge 1 commit into
CachyOS:masterfrom
ranicharradi:fix/dmcheck-exact-package-checks

Conversation

@ranicharradi

Copy link
Copy Markdown

Summary

  • Use pacman -Q "$package" for all nine installed-package checks in dmcheck.
  • Avoid substring and description matches from pacman -Qs, which can enable a display manager that is not installed.

Why

pacman -Qs ly succeeds when plymouth is installed, even if ly is absent. The Ly block can then remove the tty2 getty link and create a dangling ly@tty2.service link.

Verification

  • bash -n archiso/airootfs/usr/local/bin/dmcheck
  • git diff --check
  • Mocked pacman, rm, and ln: all nine queries used -Q, and no service actions ran when Ly was absent.

@ventureoo

Copy link
Copy Markdown
Member

Honestly, I think we need to replace it with loop & associative array.

@vnepogodin

Copy link
Copy Markdown
Member

What about using lua hah

@ventureoo

Copy link
Copy Markdown
Member

What about using lua hah

When 🥹

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.

3 participants