From 5b45de9320bfe6975124f1feb819874d94c5059f Mon Sep 17 00:00:00 2001 From: inxi-svn Date: Sat, 21 May 2011 01:36:19 +0000 Subject: [PATCH] added pekwm version number --- inxi | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) diff --git a/inxi b/inxi index 8650508..90ad0da 100755 --- a/inxi +++ b/inxi @@ -2632,7 +2632,7 @@ detect_desktop_environment() desktop_environment="Xfce${version}" elif [[ -n $( grep -is 'BLACKBOX_PID' <<< "$xprop_root" ) ]];then if [[ -n $( grep -is 'fluxbox' <<< "$ps_aux" | grep -v 'grep' ) ]];then - version=$( fluxbox --version 2>/dev/null | grep -Esi 'fluxbox [[:digit:]]' | gawk '{print $2}' ) + version=$( fluxbox --version 2>/dev/null | grep -Esi 'fluxbox ([[:digit:]]|GIT)' | gawk '{print $2}' ) if [[ -n $version ]];then version=" $version" fi @@ -2641,7 +2641,7 @@ detect_desktop_environment() desktop_environment='Blackbox' fi elif [[ -n $( grep -is 'OPENBOX_PID' <<< "$xprop_root" ) ]];then - version=$( openbox --version 2>/dev/null | grep -Esi 'openbox [[:digit:]]' | gawk '{print $2}' ) + version=$( openbox --version 2>/dev/null | grep -Esi 'openbox ([[:digit:]]|GIT)' | gawk '{print $2}' ) if [[ -n $version ]];then version=" $version" fi @@ -2654,7 +2654,7 @@ detect_desktop_environment() desktop_environment="Openbox${version}" fi elif [[ -n $( grep -is 'ICEWM' <<< "$xprop_root" ) ]];then - version=$( icewm --version 2>/dev/null | grep -Esi 'iceWM [[:digit:]]' | gawk '{gsub(/,/, ""); print $2}' ) + version=$( icewm --version 2>/dev/null | grep -Esi 'iceWM ([[:digit:]]|GIT)' | gawk '{gsub(/,/, ""); print $2}' ) if [[ -n $version ]];then version=" $version" fi @@ -2664,21 +2664,25 @@ detect_desktop_environment() # a few manual hacks for things that don't id with xprop, these are just good guesses if [[ -z $desktop_environment ]];then if [[ -n $( grep -is 'fvwm-crystal' <<< "$ps_aux" | grep -v 'grep' ) ]];then - version=$( fvwm --version 2>/dev/null | grep -Esi 'fvwm [[:digit:]]' | gawk '{print $2}' ) + version=$( fvwm --version 2>/dev/null | grep -Esi 'fvwm ([[:digit:]]|GIT)' | gawk '{print $2}' ) if [[ -n $version ]];then version=" $version" fi desktop_environment="FVWM-Crystal${version}" elif [[ -n $( grep -is 'fvwm' <<< "$ps_aux" | grep -v 'grep' ) ]];then - version=$( fvwm --version 2>/dev/null | grep -Esi 'fvwm [[:digit:]]' | gawk '{print $2}' ) + version=$( fvwm --version 2>/dev/null | grep -Esi 'fvwm ([[:digit:]]|GIT)' | gawk '{print $2}' ) if [[ -n $version ]];then version=" $version" fi desktop_environment="FVWM${version}" elif [[ -n $( grep -is 'pekwm' <<< "$ps_aux" | grep -v 'grep' ) ]];then - desktop_environment='pekwm' + version=$( pekwm --version 2>/dev/null | grep -Esi 'pekwm ([[:digit:]]|GIT)' | gawk '{print $3}' ) + if [[ -n $version ]];then + version=" $version" + fi + desktop_environment="pekwm${version}" elif [[ -n $( grep -is 'awesome' <<< "$ps_aux" | grep -v 'grep' ) ]];then - desktop_environment='Awesome' + desktop_environment="Awesome" fi fi fi