mirror of
https://github.com/smxi/inxi.git
synced 2025-01-19 08:57:57 +00:00
New version, new tarball. Got a good fix for the kde version issue from the lads at
#kde-devel, now using kf5-config --version which gives similar output to kded4 --version I use this for both 4 and 5, but since 4 has worked fine for years, I'll just use this for 5 and later.
This commit is contained in:
parent
2b22e24d2b
commit
96fe267833
28
inxi
28
inxi
|
@ -1,7 +1,7 @@
|
||||||
#!/usr/bin/env bash
|
#!/usr/bin/env bash
|
||||||
########################################################################
|
########################################################################
|
||||||
#### Script Name: inxi
|
#### Script Name: inxi
|
||||||
#### Version: 2.2.24
|
#### Version: 2.2.25
|
||||||
#### Date: 2015-06-15
|
#### Date: 2015-06-15
|
||||||
#### Patch Number: 00
|
#### Patch Number: 00
|
||||||
########################################################################
|
########################################################################
|
||||||
|
@ -1949,6 +1949,15 @@ debug_data_collector()
|
||||||
# kde 3 id
|
# kde 3 id
|
||||||
echo $KDE_FULL_SESSION &> $debug_data_dir/kde3-full-session.txt
|
echo $KDE_FULL_SESSION &> $debug_data_dir/kde3-full-session.txt
|
||||||
echo $KDE_SESSION_VERSION &> $debug_data_dir/kde-gte-4-session-version.txt
|
echo $KDE_SESSION_VERSION &> $debug_data_dir/kde-gte-4-session-version.txt
|
||||||
|
if type -p kf5-config &>/dev/null; then
|
||||||
|
kf5-config --version &> $debug_data_dir/kf5-config-version-data.txt
|
||||||
|
elif type -p kf6-config &>/dev/null; then
|
||||||
|
kf6-config --version &> $debug_data_dir/kf6-config-version-data.txt
|
||||||
|
elif type -p kf$KDE_SESSION_VERSION-config &>/dev/null; then
|
||||||
|
kf$KDE_SESSION_VERSION-config --version &> $debug_data_dir/kf$KDE_SESSION_VERSION-KSV-config-version-data.txt
|
||||||
|
else
|
||||||
|
touch $debug_data_dir/kf-config-absent
|
||||||
|
fi
|
||||||
if type -p kded4 &>/dev/null; then
|
if type -p kded4 &>/dev/null; then
|
||||||
kded4 --version &> $debug_data_dir/kded4-version-data.txt
|
kded4 --version &> $debug_data_dir/kded4-version-data.txt
|
||||||
elif type -p kded5 &>/dev/null; then
|
elif type -p kded5 &>/dev/null; then
|
||||||
|
@ -1956,7 +1965,7 @@ debug_data_collector()
|
||||||
elif type -p kded &>/dev/null; then
|
elif type -p kded &>/dev/null; then
|
||||||
kded --version &> $debug_data_dir/kded-version-data.txt
|
kded --version &> $debug_data_dir/kded-version-data.txt
|
||||||
else
|
else
|
||||||
touch $debug_data_dir/kded45-$KDE_SESSION_VERSION-absent
|
touch $debug_data_dir/kded-$KDE_SESSION_VERSION-absent
|
||||||
fi
|
fi
|
||||||
# kde 5/plasma desktop 5, this is maybe an extra package and won't be used
|
# kde 5/plasma desktop 5, this is maybe an extra package and won't be used
|
||||||
if type -p about-distro &>/dev/null; then
|
if type -p about-distro &>/dev/null; then
|
||||||
|
@ -4519,8 +4528,19 @@ get_desktop_environment()
|
||||||
# actual desktop data, so once that's in debian/ubuntu, if it gets in, add that test
|
# actual desktop data, so once that's in debian/ubuntu, if it gets in, add that test
|
||||||
if [[ $XDG_CURRENT_DESKTOP == 'KDE' || -n $KDE_SESSION_VERSION ]]; then
|
if [[ $XDG_CURRENT_DESKTOP == 'KDE' || -n $KDE_SESSION_VERSION ]]; then
|
||||||
# note the command is actually like, kded4 --version, so we construct it
|
# note the command is actually like, kded4 --version, so we construct it
|
||||||
version_data=$( kded$KDE_SESSION_VERSION --version 2>/dev/null )
|
# this was supposed to extend to 5, but 5 changed it, so it uses the more reliable way
|
||||||
version=$( grep -si '^KDE Development Platform:' <<< "$version_data" | gawk '{print $4}' )
|
if [[ $KDE_SESSION_VERSION -le 4 ]];then
|
||||||
|
version_data=$( kded$KDE_SESSION_VERSION --version 2>/dev/null )
|
||||||
|
version=$( grep -si '^KDE Development Platform:' <<< "$version_data" | gawk '{print $4}' )
|
||||||
|
else
|
||||||
|
# NOTE: this command string is almost certain to change, and break, with next major plasma desktop, ie, 6
|
||||||
|
# version=$( qdbus org.kde.plasmashell /MainApplication org.qtproject.Qt.QCoreApplication.applicationVersion 2>/dev/null )
|
||||||
|
#Qt: 5.4.2
|
||||||
|
#KDE Frameworks: 5.11.0
|
||||||
|
#kf5-config: 1.0
|
||||||
|
version_data=$( kf$KDE_SESSION_VERSION-config --version 2>/dev/null )
|
||||||
|
version=$( grep -si '^KDE Frameworks:' <<< "$version_data" | gawk '{print $NF}' )
|
||||||
|
fi
|
||||||
if [[ -z $version ]];then
|
if [[ -z $version ]];then
|
||||||
version=$KDE_SESSION_VERSION
|
version=$KDE_SESSION_VERSION
|
||||||
fi
|
fi
|
||||||
|
|
|
@ -1,3 +1,19 @@
|
||||||
|
=====================================================================================
|
||||||
|
Version: 2.2.25
|
||||||
|
Patch Version: 00
|
||||||
|
Script Date: 2015-06-15
|
||||||
|
-----------------------------------
|
||||||
|
Changes:
|
||||||
|
-----------------------------------
|
||||||
|
New version, new tarball. Got a good fix for the kde version issue from the lads at
|
||||||
|
#kde-devel, now using kf5-config --version which gives similar output to kded4 --version
|
||||||
|
|
||||||
|
I use this for both 4 and 5, but since 4 has worked fine for years, I'll just use this for 5
|
||||||
|
and later.
|
||||||
|
|
||||||
|
-----------------------------------
|
||||||
|
-- Harald Hope - Mon, 15 Jun 2015 17:49:56 -0700
|
||||||
|
|
||||||
=====================================================================================
|
=====================================================================================
|
||||||
Version: 2.2.24
|
Version: 2.2.24
|
||||||
Patch Version: 00
|
Patch Version: 00
|
||||||
|
|
Loading…
Reference in a new issue