summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDaniel Napora <napcok@gmail.com>2013-11-04 17:03:06 +0100
committerDaniel Napora <napcok@gmail.com>2013-11-04 17:03:06 +0100
commit77106c5c47883866b573f88b3dc0d75b5ae85bb0 (patch)
tree5ebf23cf06c510fb8c033e4d45579f5406e80445
parent822f47886fdd28a2be7473d27fc493949a657d51 (diff)
downloadmageiawelcome-77106c5c47883866b573f88b3dc0d75b5ae85bb0.tar
mageiawelcome-77106c5c47883866b573f88b3dc0d75b5ae85bb0.tar.gz
mageiawelcome-77106c5c47883866b573f88b3dc0d75b5ae85bb0.tar.bz2
mageiawelcome-77106c5c47883866b573f88b3dc0d75b5ae85bb0.tar.xz
mageiawelcome-77106c5c47883866b573f88b3dc0d75b5ae85bb0.zip
check for installed rpms changed
-rw-r--r--usr/share/mageiawelcome/apps.csv94
-rw-r--r--usr/share/mageiawelcome/helpers.py15
2 files changed, 56 insertions, 53 deletions
diff --git a/usr/share/mageiawelcome/apps.csv b/usr/share/mageiawelcome/apps.csv
index 6f8fb52..0177a89 100644
--- a/usr/share/mageiawelcome/apps.csv
+++ b/usr/share/mageiawelcome/apps.csv
@@ -1,47 +1,47 @@
-0-IKONA|1-RPM|2-NAZWA|3-GRUPA|4-OPIS|5-TEST|6-START|7-REPO
-codecs-audio|task-codec-audio|Audio Multimedia Codecs|audio featured|Various Multimedia Codecs for Audio|test|false|tainted|
-codecs-video|task-codec-video|Video Multimedia Codecs|video featured|Various Multimedia Codecs for Video|test|false|tainted|
-flash-player-plugin|flash-player-plugin|Flash plugin|internet featured|Flash browser plugin|/usr/bin/flash-player-properties|false|non-free|
-steam|steam|Steam|games|Steam Client|/usr/bin/steam|steam|non-free|
-megaglest|megaglest|Megaglest|games|3D Real Time Strategy|/usr/games/megaglest|megaglest||
-sauerbraten|sauerbraten|Sauerbraten|games|Multi-player/single-player first person shooter game|/usr/bin/sauerbraten|sauerbraten|non-free|
-supertux|supertux|Supertux|games|Classic 2d jump 'n run sidescroller with tux |/usr/games/supertux2|supertux2||
-warzone2100|warzone2100|Warzone 2100|games|Postnuclear realtime strategy|/usr/games/warzone2100|warzone2100||
-wesnoth|wesnoth|Battle for Wesnoth|games|Fantasy turn-based strategy game|/usr/games/wesnoth|wesnoth||
-0ad|0ad|O.A.D|games|RTS Game of Ancient Warfare|/bin/0ad|0ad||
-blender|blender|Blender|graphics|3d modeller/renderer|/bin/blender|blender||
-mypaint|mypaint|MyPaint|graphics|Painting Program|/bin/mypaint|mypaint||
-gimp|gimp|GIMP|graphics|The GNU image manipulation program|/bin/gimp|gimp||
-inkscape|inkscape|Inkscape|graphics|Vector graphics editor|/bin/inkscape|inkscape||
-scribus|scribus|Scribus|graphics|Desktop Publishing Program|/bin/scribus|scribus||
-digikam|digikam|Digikam|graphics|Digital photo management application|/bin/digikam|digikam||
-darktable|darktable|Darktable|graphics|Virtual lighttable and darkroom for photographers|/bin/darktable|darktable||
-pidgin|pidgin|Pidgin|internet|Multi-protocol instant messaging client|/bin/pidgin|pidgin||
-skype|skype|Skype|internet featured|Call, see, message and share with others|/bin/skype|skype|non-free|
-filezilla|filezilla|Filezilla|internet|Full-featured graphical ftp/ftps/sftp client|/bin/filezilla|filezilla||
-firefox|firefox|Firefox|internet featured|Next generation web browser|/bin/firefox|firefox||
-qbittorrent|qbittorrent|Qbittorrent|internet featured|Lightweight but feature rich bittorrent client|/bin/qbittorrent|qbittorrent||
-opera|opera|Opera|internet|Fast and secure web browser and internet suite|/bin/opera|opera|non-free|
-chromium|chromium-browser|Chromium|internet|Fast Webbrowser|/usr/bin/chromium-browser|chromium-browser||
-amule|amule|Amule|internet|File sharing client compatible with eDonkey|/bin/amule|amule||
-thunderbird|thunderbird|Thunderbird|internet|E-mail, news and RSS client|/usr/bin/thunderbird|thunderbird||
-claws-mail|claws-mail|Claws Mail|internet|Fast e-mail client|/bin/claws-mail|claws-mail||
-smplayer|smplayer|Smplayer|video featured|Media Player|/usr/bin/smplayer|smplayer||
-kdenlive|kdenlive|Kdenlive|video|A non-linear video editing application|/usr/bin/kdenlive|kdenlive||
-vlc|vlc|VLC|video featured|Multimedia player and streamer|/bin/vlc|vlc||
-xbmc|xbmc|XBMC|video|Media Center|/bin/xbmc|xbmc||
-qmmp|qmmp|Qmmp|audio|Audio Player similiar to Winamp|/bin/qmmp|qmmp||
-clementine|clementine|Clementine|audio|Modern music player and library organizer|/bin/clementine|clementine||
-radiotray|radiotray|Radiotray|audio|Online radio streaming player|/bin/radiotray|radiotray||
-soundkonverter|soundkonverter|Soundkonverter|audio|An audio file converter, CD ripper and replay gain tool|/bin/soundkonverter|soundkonverter||
-eclipse|eclipse|Eclipse|programming|Extensible tool platform and java ide|/bin/eclipse|eclipse||
-codeblocks|codeblocks|CodeBlocks|programming|A C++ IDE|/bin/codeblocks|codeblocks||
-qt-creator|qt-creator|Qt Creator|programming|Lightweight IDE for qt|/bin/qtcreator|qtcreator||
-anjuta|anjuta|Anjuta|programming|IDE for C and C++|/bin/anjuta|anjuta||
-lazarus|lazarus|Lazarus|programming|IDE for free pascal|/bin/lazarus|lazarus||
-k3b|k3b|K3b|system|Sophisticated cd/dvd burning application|/bin/k3b|k3b||
-gparted|gparted|GParted|system|Partition editor|/bin/gparted|gparted||
-k9copy|k9copy|K9copy|system|k9copy helps making backups of your video DVDs |/bin/k9copy|k9copy||
-bleachbit|bleachbit|BleachBit|system|Clean junk to free disk space and to maintain privacy |/bin/bleachbit|bleachbit||
-system-config-printer|system-config-printer|System Config Printer|system|A printer administration tool|/usr/bin/system-config-printer|system-config-printer||
-virtualbox|virtualbox|VirtualBox|system|Virtualization software|/usr/bin/VirtualBox|VirtualBox||
+0-IKONA|1-RPM|2-NAZWA|3-GRUPA|4-OPIS|5-START|6-REPO
+codecs-audio|task-codec-audio|Audio Multimedia Codecs|audio featured|Various Multimedia Codecs for Audio|false|tainted|
+codecs-video|task-codec-video|Video Multimedia Codecs|video featured|Various Multimedia Codecs for Video|false|tainted|
+flash-player-plugin|flash-player-plugin|Flash plugin|internet featured|Flash browser plugin|false|non-free|
+steam|steam|Steam|games|Steam Client|steam|non-free|
+megaglest|megaglest|Megaglest|games|3D Real Time Strategy|megaglest||
+sauerbraten|sauerbraten|Sauerbraten|games|Multi-player/single-player first person shooter game|sauerbraten|non-free|
+supertux|supertux|Supertux|games|Classic 2d jump 'n run sidescroller with tux |supertux2||
+warzone2100|warzone2100|Warzone 2100|games|Postnuclear realtime strategy|warzone2100||
+wesnoth|wesnoth|Battle for Wesnoth|games|Fantasy turn-based strategy game|wesnoth||
+0ad|0ad|O.A.D|games|RTS Game of Ancient Warfare|0ad||
+blender|blender|Blender|graphics|3d modeller/renderer|blender||
+mypaint|mypaint|MyPaint|graphics|Painting Program|mypaint||
+gimp|gimp|GIMP|graphics|The GNU image manipulation program|gimp||
+inkscape|inkscape|Inkscape|graphics|Vector graphics editor|inkscape||
+scribus|scribus|Scribus|graphics|Desktop Publishing Program|scribus||
+digikam|digikam|Digikam|graphics|Digital photo management application|digikam||
+darktable|darktable|Darktable|graphics|Virtual lighttable and darkroom for photographers|darktable||
+pidgin|pidgin|Pidgin|internet|Multi-protocol instant messaging client|pidgin||
+skype|get-skype|Skype|internet featured|Call, see, message and share with others|skype|non-free|
+filezilla|filezilla|Filezilla|internet|Full-featured graphical ftp/ftps/sftp client|filezilla||
+firefox|firefox|Firefox|internet featured|Next generation web browser|firefox||
+qbittorrent|qbittorrent|Qbittorrent|internet featured|Lightweight but feature rich bittorrent client|qbittorrent||
+opera|opera|Opera|internet|Fast and secure web browser and internet suite|opera|non-free|
+chromium|chromium-browser|Chromium|internet|Fast Webbrowser|chromium-browser||
+amule|amule|Amule|internet|File sharing client compatible with eDonkey|amule||
+thunderbird|thunderbird|Thunderbird|internet|E-mail, news and RSS client|thunderbird||
+claws-mail|claws-mail|Claws Mail|internet|Fast e-mail client|claws-mail||
+smplayer|smplayer|Smplayer|video featured|Media Player|smplayer||
+kdenlive|kdenlive|Kdenlive|video|A non-linear video editing application|kdenlive||
+vlc|vlc|VLC|video featured|Multimedia player and streamer|vlc||
+xbmc|xbmc|XBMC|video|Media Center|xbmc||
+qmmp|qmmp|Qmmp|audio|Audio Player similiar to Winamp|qmmp||
+clementine|clementine|Clementine|audio|Modern music player and library organizer|clementine||
+radiotray|radiotray|Radiotray|audio|Online radio streaming player|radiotray||
+soundkonverter|soundkonverter|Soundkonverter|audio|An audio file converter, CD ripper and replay gain tool|soundkonverter||
+eclipse|eclipse|Eclipse|programming|Extensible tool platform and java ide|eclipse||
+codeblocks|codeblocks|CodeBlocks|programming|A C++ IDE|codeblocks||
+qt-creator|qt-creator|Qt Creator|programming|Lightweight IDE for qt|qtcreator||
+anjuta|anjuta|Anjuta|programming|IDE for C and C++|anjuta||
+lazarus|lazarus|Lazarus|programming|IDE for free pascal|lazarus||
+k3b|k3b|K3b|system|Sophisticated cd/dvd burning application|k3b||
+gparted|gparted|GParted|system|Partition editor|gparted||
+k9copy|k9copy|K9copy|system|k9copy helps making backups of your video DVDs |k9copy||
+bleachbit|bleachbit|BleachBit|system|Clean junk to free disk space and to maintain privacy |bleachbit||
+system-config-printer|system-config-printer|System Config Printer|system|A printer administration tool|system-config-printer||
+virtualbox|virtualbox|VirtualBox|system|Virtualization software|VirtualBox||
diff --git a/usr/share/mageiawelcome/helpers.py b/usr/share/mageiawelcome/helpers.py
index 3468892..cac5578 100644
--- a/usr/share/mageiawelcome/helpers.py
+++ b/usr/share/mageiawelcome/helpers.py
@@ -4,25 +4,28 @@
import csv
import os
+def is_installed(name):
+ return os.WEXITSTATUS(os.system('rpm -q --quiet ' + name))
+
def get_listapp():
listapp = ''
with open("apps.csv", 'rb') as f:
mycsv = csv.reader(f,delimiter='|')
mycsv.next()
for r in mycsv:
- if (r[6] == 'false'):
+ if (r[5] == 'false'):
start_btn = ""
else:
- start_btn = "<button class='cmd small pill green' data-run='"+ r[6] + "'><i class='icon-ok-sign'> </i> Launch</button>"
- if (r[7] != ''):
- label = "<span class='label red'>" + r[7] + "</span>"
+ start_btn = "<button class='cmd small pill green' data-run='"+ r[5] + "'><i class='icon-ok-sign'> </i> Launch</button>"
+ if (r[6] != ''):
+ label = "<span class='label red'>" + r[6] + "</span>"
else:
label = ""
- if ( not os.path.isfile(r[5])):# DO ZAINSTALOWANIA
+ if ( is_installed(r[1]) != 0):# NOT INSTALLED
listapp += "<li class='" + r[3] +"' id='" + r[0] + "'><img class=icon src=img/" + r[0] + ".png /><div class='chkbox'><input type='checkbox' datasrc='" + r[1] +"'></div> \
<h6>" + r[2] + "</h6><p class=description>" + r[4] + "</p>" + start_btn + label + "<button class='inst small pill' data-rpm='" + r[1] + "'><i class='icon-circle-arrow-down'> </i> Install</button></li>"
- else: # JEST ZAINSTALOWANY
+ else: # INSTALLED
listapp += "<li class='urpme " + r[3] +"' id='" + r[0] + "'><img class=icon src=img/" + r[0] + ".png /><div class='chkbox'></div> \
<h6>" + r[2] + "</h6><p class=description>" + r[4] + "</p>" + start_btn + label + "<button class='uninst small pill red' data-rpm='" + r[1] + "'><i class='icon-minus-sign'> </i> remove</button></li>"
return listapp