Skip to content

start-pulseaudio-x11: fix KDE version check

Rickie Schroeder requested to merge (removed):patch-1 into master

Current check wasn't working because it tried to grep $DESKTOP_SESSION.desktop in work dir which doesn't contain any $DESKTOP_SESSION.desktop files.

It also relied on $DESKTOP_SESSION env variable which isn't guaranteed to exist if session is started without display manager like sddm.

New approach greps hardcoded path /usr/share/xsessions/plasma.desktop if it exists with assumption this is where .desktop file for KDE plasma is installed.

This also changes legacy backticks to modern $(...) as recommended by shellcheck: https://github.com/koalaman/shellcheck/wiki/SC2006

Fixes #751 (closed)

Edited by Rickie Schroeder

Merge request reports