From ef39bbc078a3f14ce22825fc7e5d0565bbe5a936 Mon Sep 17 00:00:00 2001 From: Michael Straube Date: Sat, 19 May 2018 14:19:38 +0200 Subject: [PATCH] wm_version: add case for kwin --- neofetch | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/neofetch b/neofetch index 13dab3f4..7c22e364 100755 --- a/neofetch +++ b/neofetch @@ -1594,8 +1594,10 @@ get_wm() { -e "tinywm")" if [[ "$wm_version" == "on" && "$wm" ]]; then - wmv="$("${wm,,}" --version || "${wm,,}" -v 2>&1)" - wmv="$wm ${wmv:-$("${wm,,}_x11" -v || "${wm,,}_wayland" -v)}" + case "$wm" in + "KWin") wmv="$wm $("${wm,,}_x11" -v || "${wm,,}_wayland" -v)" ;; + *) wmv="$("${wm,,}" --version || "${wm,,}" -v 2>&1)" ;; + esac wmv="${wmv/$wm ${wm}?/$wm }" wmv="${wmv/$wm $wm/$wm}" wmv="${wmv/copyright*}"