mirror of
https://github.com/smxi/inxi.git
synced 2024-11-17 00:31:19 +00:00
xfce version numbers added
This commit is contained in:
parent
15b9351a0a
commit
559b049add
18
inxi
18
inxi
|
@ -2604,10 +2604,22 @@ detect_desktop_environment()
|
|||
elif [[ -n $( type -p xprop ) ]];then
|
||||
xprop_root="$( xprop -root 2>/dev/null )"
|
||||
ps_aux="$( ps aux )"
|
||||
if [[ -n $( grep -is '\"xfce4\"' <<< "$xprop_root" ) ]];then
|
||||
desktop_environment='Xfce4'
|
||||
if [[ -n $( grep -Eis '\"xfce4\"' <<< "$xprop_root" ) ]];then
|
||||
version=$( xfdesktop --version 2>/dev/null | grep -Eosi 'xfdesktop version [0-9\.]+' | gawk '{print $3}' )
|
||||
if [[ -n $version ]];then
|
||||
version=" $version"
|
||||
else
|
||||
version="4"
|
||||
fi
|
||||
desktop_environment="Xfce${version}"
|
||||
elif [[ -n $( grep -is '\"xfce5\"' <<< "$xprop_root" ) ]];then
|
||||
desktop_environment='Xfce5'
|
||||
version=$( xfdesktop --version 2>/dev/null | grep -Eosi 'xfdesktop version [0-9\.]+' | gawk '{print $3}' )
|
||||
if [[ -n $version ]];then
|
||||
version=" $version"
|
||||
else
|
||||
version="5"
|
||||
fi
|
||||
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}' )
|
||||
|
|
Loading…
Reference in a new issue