diff --git a/PKGBUILD b/PKGBUILD index 6b61cfd..1dc9f5f 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -3,44 +3,52 @@ pkgname=kdeplasma-applets-pytextmonitor _pkgname=py-text-monitor -pkgver=1.3.4 -pkgrel=6 +pkgver=1.3.5 +pkgrel=1 _dtengine=ext-sysmon _dtver=1.2 pkgdesc="Minimalistic Plasmoid script written on Python2. It looks like widgets in awesome-wm" -arch=(any) +arch=('i686' 'x86_64') url="https://github.com/arcan1s/pytextmonitor" license=('GPL') depends=('kdebase-workspace' 'kdebindings-python2' 'lm_sensors' 'net-tools') -optdepends=("hddtemp: for HDD temperature monitor" - "catalyst: for GPU monitor" - "nvidia-utils: for GPU monitor") -makedepends=('cmake' 'automoc4') +optdepends=('hddtemp: for HDD temperature monitor' + '775bc3a6057f2dc1696f09b8d315a3e9' + '775bc3a6057f2dc1696f09b8d315a3e9') +makedepends=('automoc4' 'cmake') source=(https://github.com/arcan1s/pytextmonitor/releases/download/V.${pkgver}/${_pkgname}-${pkgver}.plasmoid https://github.com/arcan1s/pytextmonitor/releases/download/V.${pkgver}/${_dtengine}-${_dtver}.zip) install=${pkgname}.install -md5sums=('7cca5fd76735add215f35d406c020dea' - '9b547781732ab19ad103710b7bd07d8d') +md5sums=('d99c8a152693b6b10ebe8fb1a076a333' + '775bc3a6057f2dc1696f09b8d315a3e9') build () { -# build dataengine + # build dataengine if [ -d ${srcdir}/${_dtengine}/build ]; then rm -r ${srcdir}/${_dtengine}/build fi mkdir ${srcdir}/${_dtengine}/build && cd ${srcdir}/${_dtengine}/build - cmake -DCMAKE_INSTALL_PREFIX=`kde4-config --prefix` -DCMAKE_BUILD_TYPE=Release ../ - make || return 1 + cmake -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_INSTALL_PREFIX=`kde4-config --prefix` \ + ../ + make } package() { -# install dataengine + # install dataengine cd ${srcdir}/${_dtengine}/build - make DESTDIR=${pkgdir} install || return 1 + make DESTDIR=${pkgdir} install -# install plasmoid - install -D ${srcdir}/metadata.desktop ${pkgdir}/`kde4-config --prefix`/share/kde4/services/${_pkgname}.desktop || return 1 - install -D ${srcdir}/metadata.desktop ${pkgdir}/`kde4-config --prefix`/share/apps/plasma/plasmoids/${_pkgname}/metadata.desktop || return 1 - cp -r ${srcdir}/contents ${pkgdir}/`kde4-config --prefix`/share/apps/plasma/plasmoids/${_pkgname}/ || return 1 + # install plasmoid + install -D -m644 ${srcdir}/metadata.desktop \ + ${pkgdir}/`kde4-config --prefix`/share/kde4/services/${_pkgname}.desktop + install -D -m644 ${srcdir}/metadata.desktop \ + ${pkgdir}/`kde4-config --prefix`/share/apps/plasma/plasmoids/${_pkgname}/metadata.desktop + mkdir -p ${pkgdir}/`kde4-config --prefix`/share/apps/plasma/plasmoids/${_pkgname}/contents/{code,ui} + install -m644 ${srcdir}/contents/code/* \ + -t ${pkgdir}/`kde4-config --prefix`/share/apps/plasma/plasmoids/${_pkgname}/contents/code + install -m644 ${srcdir}/contents/ui/* \ + -t ${pkgdir}/`kde4-config --prefix`/share/apps/plasma/plasmoids/${_pkgname}/contents/ui } diff --git a/ext-sysmon-1.2.zip b/ext-sysmon-1.2.zip index 6ea64cd..efeb97b 100644 Binary files a/ext-sysmon-1.2.zip and b/ext-sysmon-1.2.zip differ diff --git a/kdeplasma-applets-pytextmonitor.install b/kdeplasma-applets-pytextmonitor.install index 946f255..7fa6471 100644 --- a/kdeplasma-applets-pytextmonitor.install +++ b/kdeplasma-applets-pytextmonitor.install @@ -11,16 +11,10 @@ EOF post_upgrade() { - cat << EOF -Update plasmoids... -EOF - kbuildsycoca4 > /dev/null 2>&1 + post_install } post_remove() { - cat << EOF -Update plasmoids... -EOF - kbuildsycoca4 > /dev/null 2>&1 + post_install } diff --git a/py-text-monitor-1.3.4.plasmoid b/py-text-monitor-1.3.5.plasmoid similarity index 75% rename from py-text-monitor-1.3.4.plasmoid rename to py-text-monitor-1.3.5.plasmoid index c9f2503..7c5e1a6 100644 Binary files a/py-text-monitor-1.3.4.plasmoid and b/py-text-monitor-1.3.5.plasmoid differ diff --git a/sources/contents/code/main.py b/sources/contents/code/main.py index 90008e1..9d0ffbc 100644 --- a/sources/contents/code/main.py +++ b/sources/contents/code/main.py @@ -69,8 +69,8 @@ class pyTextWidget(plasmascript.Applet): try: interfaces = [] for line in commands.getoutput("ifconfig -a").split("\n"): - if ((line != '') and (line[0] != ' ') and (line[0:3] != 'lo:')): - interfaces.append(line.split(":")[0]) + if ((line != '') and (line[0] != ' ') and (line.split(":")[0].split()[0] != 'lo')): + interfaces.append(line.split(":")[0].split()[0]) for device in interfaces: if (commands.getoutput("ifconfig " + device + " | grep 'inet '") != ''): diff --git a/sources/metadata.desktop b/sources/metadata.desktop index 8034900..045edb9 100644 --- a/sources/metadata.desktop +++ b/sources/metadata.desktop @@ -12,7 +12,7 @@ X-Plasma-RequiredExtensions=LaunchApp,LocalIO,FileDialog X-KDE-PluginInfo-Author=Evgeniy Alekseev aka arcanis X-KDE-PluginInfo-Email=esalexeev@gmail.com X-KDE-PluginInfo-Name=py-text-monitor -X-KDE-PluginInfo-Version=1.3.4 +X-KDE-PluginInfo-Version=1.3.5 X-KDE-PluginInfo-Website=http://kde-look.org/ X-KDE-PluginInfo-Category=System Information X-KDE-PluginInfo-Depends=