more version info for other desktops

This commit is contained in:
inxi-svn 2011-05-19 05:52:08 +00:00
parent 962f1b9665
commit 4bb100ed8e

29
inxi
View file

@ -2610,21 +2610,40 @@ detect_desktop_environment()
desktop_environment='Xfce5'
elif [[ -n $( grep -is 'BLACKBOX_PID' <<< "$xprop_root" ) ]];then
if [[ -n $( grep -is 'fluxbox' <<< "$ps_aux" | grep -v 'grep' ) ]];then
desktop_environment='Fluxbox'
version=$( fluxbox --version 2>/dev/null | grep -Esi 'fluxbox [[:digit:]]' | gawk '{print $2}' )
if [[ -n $version ]];then
version=" $version"
fi
desktop_environment="Fluxbox${version}"
else
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}' )
if [[ -n $version ]];then
version=" $version"
fi
if [[ -n $( grep -is 'lxde' <<< "$ps_aux" | grep -v 'grep' ) ]];then
desktop_environment='LXDE'
if [[ -n $version ]];then
version=" (Openbox $version)"
fi
desktop_environment="LXDE${version}"
else
desktop_environment='Openbox'
desktop_environment="Openbox${version}"
fi
# a few manual hacks for things that don't id with xprop, these are just good guesses
elif [[ -n $( grep -is 'fvwm-crystal' <<< "$ps_aux" | grep -v 'grep' ) ]];then
desktop_environment='FVWM-Crystal'
version=$( fvwm --version 2>/dev/null | grep -Esi 'fvwm [[:digit:]]' | 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
desktop_environment='FVWM'
version=$( fvwm --version 2>/dev/null | grep -Esi 'fvwm [[:digit:]]' | 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'
elif [[ -n $( grep -is 'awesome' <<< "$ps_aux" | grep -v 'grep' ) ]];then