Skip to content

actions: check that the tweak package got installed - #306

Open
Rockykln wants to merge 1 commit into
CachyOS:developfrom
Rockykln:fix-tweak-install-check
Open

Rockykln wants to merge 1 commit into
CachyOS:developfrom
Rockykln:fix-tweak-install-check

Conversation

@Rockykln

Copy link
Copy Markdown

When a tweak's package is missing, Hello runs pacman -S <pkg> in a terminal and treats the tweak as enabled if run_cmd_terminal returns true. But the command ends with read -p 'Press enter to exit', so the exit status is never pacman's. If you cancel the install (close pkexec, answer "n" or close the window), the checkbox stays checked and Hello tries to enable a unit that doesn't exist.

Someone hit this on the forum: https://discuss.cachyos.org/t/5369 (post 12).

This checks whether the package is actually installed once the terminal closes. If not, the checkbox gets reset and the existing "Package '…' has not been installed!" message shows up.

Tested with a local build where one tweak pointed to a package that doesn't exist: cancelling the install now unchecks the box and shows the message.

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