xe20180114_210806
This commit is contained in:
parent
4f8c7c4660
commit
70e1c024b1
11 changed files with 243 additions and 0 deletions
0
.builddeb
Normal file
0
.builddeb
Normal file
0
.update
Normal file
0
.update
Normal file
29
LICENSE
Normal file
29
LICENSE
Normal file
|
@ -0,0 +1,29 @@
|
|||
BSD 3-Clause License
|
||||
|
||||
Copyright (c) 2017, Jakobus Schürz
|
||||
All rights reserved.
|
||||
|
||||
Redistribution and use in source and binary forms, with or without
|
||||
modification, are permitted provided that the following conditions are met:
|
||||
|
||||
* Redistributions of source code must retain the above copyright notice, this
|
||||
list of conditions and the following disclaimer.
|
||||
|
||||
* Redistributions in binary form must reproduce the above copyright notice,
|
||||
this list of conditions and the following disclaimer in the documentation
|
||||
and/or other materials provided with the distribution.
|
||||
|
||||
* Neither the name of the copyright holder nor the names of its
|
||||
contributors may be used to endorse or promote products derived from
|
||||
this software without specific prior written permission.
|
||||
|
||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
58
Makefile
Normal file
58
Makefile
Normal file
|
@ -0,0 +1,58 @@
|
|||
DIR=$(shell basename $(CURDIR))
|
||||
|
||||
VERSION=`gawk '$$1 == "Version:"{print $$2}' $(DIR)/DEBIAN/control`
|
||||
ARCH=`gawk '$$1 == "Architecture:"{print $$2}' $(DIR)/DEBIAN/control`
|
||||
COMMIT = $(shell date "+xe%Y%m%d_%H%M%S")
|
||||
|
||||
SUBDIRS := $(shell find $(DIR) -type d -print)
|
||||
FILTER := $(abspath .git% %.deb .publish-git .builddeb %.swp Makefile)
|
||||
FILTERORIG := $(abspath .git% %.deb .publish-git .builddeb %.swp Makefile) $(shell test -e noupdate.files && cat noupdate.files) /DEBIAN%
|
||||
FILES := $(filter-out $(FILTER), $(abspath $(shell find . -mindepth 1 -type f -print) ))
|
||||
ORIGS := $(filter-out $(FILTERORIG), $(realpath $(subst ./$(DIR),,$(shell sudo find . -mindepth 2 -type f -print))))
|
||||
#FILES := $(filter-out $(FILTER), $(abspath $(shell find . -mindepth 1 -type f -exec echo {} \;) ))
|
||||
#ORIGS := $(filter-out $(FILTERORIG), $(realpath $(subst ./$(DIR),,$(shell sudo find . -mindepth 2 -type f -exec echo {] \;))))
|
||||
FILESGIT := $(filter-out $(abspath .git%), $(abspath $(shell find . -mindepth 1 -type f -print)))
|
||||
|
||||
#all: $(DIR)/DEBIAN/control
|
||||
|
||||
#$(DIR)/DEBIAN/control: $(FILES)
|
||||
|
||||
-include Makefile.repo
|
||||
|
||||
all: .builddeb
|
||||
@#echo FILE $(FILESGIT)
|
||||
|
||||
.builddeb: $(FILES)
|
||||
@#echo FILT $(FILTER)
|
||||
@#echo FILE $(FILES)
|
||||
@echo `gawk -f ../increment.awk $(DIR)/DEBIAN/control`
|
||||
sed -e "s/^Version:.*/`gawk -f ../increment.awk $(DIR)/DEBIAN/control`/" $(DIR)/DEBIAN/control > $(DIR)/DEBIAN/control.tmp
|
||||
mv $(DIR)/DEBIAN/control.tmp $(DIR)/DEBIAN/control
|
||||
fakeroot dpkg-deb --build $(DIR) "$(DIR)_$(VERSION)_$(ARCH).deb"
|
||||
ln -sf "$(DIR)_$(VERSION)_$(ARCH).deb" "$(DIR)_current_$(ARCH).deb"
|
||||
aptly repo add xundeenergie "$(DIR)_$(VERSION)_$(ARCH).deb"
|
||||
touch .builddeb
|
||||
|
||||
buildonlydeb: $(FILES)
|
||||
@#echo FILT $(FILTER)
|
||||
@#echo FILE $(FILES)
|
||||
@echo `gawk -f ../increment.awk $(DIR)/DEBIAN/control`
|
||||
sed -e "s/^Version:.*/`gawk -f ../increment.awk $(DIR)/DEBIAN/control`/" $(DIR)/DEBIAN/control > $(DIR)/DEBIAN/control.tmp
|
||||
mv $(DIR)/DEBIAN/control.tmp $(DIR)/DEBIAN/control
|
||||
fakeroot dpkg-deb --build $(DIR) "$(DIR)_$(VERSION)_$(ARCH).deb"
|
||||
ln -sf "$(DIR)_$(VERSION)_$(ARCH).deb" "$(DIR)_current_$(ARCH).deb"
|
||||
|
||||
.update: $(ORIGS)
|
||||
@#for i in $(ORIGS); do $$i;done
|
||||
@echo "Copy originals to $(DIR)"
|
||||
@for i in $(ORIGS); do sudo cp -uv $$i $(DIR)$$i;done
|
||||
touch .update
|
||||
|
||||
.publish-git: $(FILESGIT)
|
||||
fakeroot git add .
|
||||
fakeroot git commit -m $(COMMIT) && git push origin master || exit 0
|
||||
touch .publish-git
|
||||
|
||||
|
||||
pull-git:
|
||||
git pull origin || exit 0
|
17
system-notification/DEBIAN/control
Normal file
17
system-notification/DEBIAN/control
Normal file
|
@ -0,0 +1,17 @@
|
|||
Package: system-notification
|
||||
Version: 0.1.5
|
||||
Section: news
|
||||
Priority: extra
|
||||
Architecture: all
|
||||
Maintainer: Jakobus Schürz <jakob@xundeenergie.at>
|
||||
Homepage: http://github.com/xundeenergie/system-notification
|
||||
Provides: system-notification
|
||||
Depends: python3, dbus
|
||||
Recommends:
|
||||
Suggests:
|
||||
Description: Send notifications from a system-daemon or cronjob to all desktop-notification-daemons
|
||||
Send via dbus-systembus a message to the graphical-session to each logged in users sessionbus to push notifications to the notification-daemon.
|
||||
This package contains a user-service which listens on systembus and send the notification to the sessionbus. Starting it via xdg-autostart
|
||||
Send Messages to at.xundeenergie.notifications.Notification and /at/xundeenergie/notifications via dbus-send --system or dbus-bindings from your favorit language
|
||||
|
||||
|
|
@ -0,0 +1,107 @@
|
|||
[Desktop Entry]
|
||||
Version=1.0
|
||||
Name=Notifications service for mkbackup
|
||||
Name[ar]=تنبيهات
|
||||
Name[ast]=Notificaciones
|
||||
Name[bg]=Уведомления
|
||||
Name[ca]=Notificacions
|
||||
Name[cs]=Oznámení
|
||||
Name[da]=Beskeder
|
||||
Name[de]=Benachrichtigungen für mkbackup
|
||||
Name[el]=Ειδοποιήσεις
|
||||
Name[en_AU]=Notifications
|
||||
Name[en_GB]=Notifications
|
||||
Name[es]=Notificaciones
|
||||
Name[eu]=Berri-emateak
|
||||
Name[fi]=Ilmoitukset
|
||||
Name[fr]=Notifications
|
||||
Name[gl]=Notificacións
|
||||
Name[he]=התראות
|
||||
Name[hr]=Obavijesti
|
||||
Name[hu]=Értesítések
|
||||
Name[id]=Notifikasi
|
||||
Name[is]=Tilkynningar
|
||||
Name[it]=Notifiche
|
||||
Name[ja]=通知
|
||||
Name[kk]=Хабарламалар
|
||||
Name[ko]=알림
|
||||
Name[lt]=Pranešimai
|
||||
Name[lv]=Paziņojumi
|
||||
Name[ms]=Pemberitahuan
|
||||
Name[nb]=Varsling
|
||||
Name[nl]=Meldingen
|
||||
Name[oc]=Notificacions
|
||||
Name[pa]=ਨੋਟੀਫਿਕੇਸ਼ਨ
|
||||
Name[pl]=Powiadomienia
|
||||
Name[pt]=Notificações
|
||||
Name[pt_BR]=Notificações
|
||||
Name[ro]=Notificări
|
||||
Name[ru]=Оповещения
|
||||
Name[sk]=Oznámenia
|
||||
Name[sl]=Obvestila
|
||||
Name[sq]=Njoftime
|
||||
Name[sr]=Обавештења
|
||||
Name[sv]=Notifieringar
|
||||
Name[th]=การแจ้งเหตุ
|
||||
Name[tr]=Bildiriler
|
||||
Name[ug]=ئۇقتۇرۇشلار
|
||||
Name[uk]=Сповіщення
|
||||
Name[vi]=Thông báo
|
||||
Name[zh_CN]=通知
|
||||
Name[zh_TW]=通知
|
||||
Comment=Customize how notifications appear on your screen
|
||||
Comment[ar]=خصص كيف تظهر التنبيهات على الشاشة
|
||||
Comment[ast]=Personaliza cómo apaecen les notificaciones na to pantalla
|
||||
Comment[bg]=Настройване на изгледа на уведомленията на екрана
|
||||
Comment[ca]=Personalitzeu com es mostren les notificacions
|
||||
Comment[cs]=Upravte způsob, jakým se budou oznámení zobrazovat
|
||||
Comment[da]=Tilpas hvordan beskeder fremkommer på din skærm
|
||||
Comment[de]=Das Erscheinungsbild von Benachrichtigungen anpassen
|
||||
Comment[el]=Προσαρμογή του τρόπου εμφάνισης των ειδοποιήσεων στην οθόνη
|
||||
Comment[en_AU]=Customise how notifications appear on your screen
|
||||
Comment[en_GB]=Customise how notifications appear on your screen
|
||||
Comment[es]=Personalice cómo aparecen las notificaciones en pantalla
|
||||
Comment[eu]=Pertsonalizatu berri-emateak zure pantailan nola agertuko diren
|
||||
Comment[fi]=Mukauta näytöllesi ilmestyvien ilmoitusten toimintaa
|
||||
Comment[fr]=Personnaliser la manière dont les notifications apparaissent sur votre écran
|
||||
Comment[gl]=Personalice como se mostran as notificacións na súa pantalla
|
||||
Comment[he]=התאם מראה התראות על המסך שלך
|
||||
Comment[hr]=Prilagodite kako će se obavijesti prikazivati na vašem ekranu
|
||||
Comment[hu]=A képernyőn megjelenő értesítések megjelenésének személyre szabása
|
||||
Comment[id]=Sesuaikan bagaimana notifikasi tampak di layar anda
|
||||
Comment[is]=Sérsníða hvernig tilkynningar birtast á skjánum þínum
|
||||
Comment[it]=Personalizzazione del modo in cui le notifiche appaiono sullo schermo
|
||||
Comment[ja]=画面上にどのように通知するか設定します
|
||||
Comment[kk]=Хабарламалар көрсетілуін таңдаңыз
|
||||
Comment[ko]=알림을 화면에 어떻게 띄울 것인지 설정합니다
|
||||
Comment[lt]=Tinkinti kaip atrodys pranešimai jūsų ekrane
|
||||
Comment[lv]=Pielāgojiet, kā paziņojumu parādās uz jūsu ekrāna
|
||||
Comment[ms]=Suaikan bagaimana pemberitahuan muncul atas skrin anda
|
||||
Comment[nb]=Tilpass visning av varsler på skjermen din
|
||||
Comment[nl]=Weergave van meldingen aanpassen
|
||||
Comment[oc]=Personalizar lo biais que las notificacions apareisson sus vòstre ecran
|
||||
Comment[pa]=ਕਸਟਮਾਈਜ਼ ਕਰੋ ਕਿ ਤੁਹਾਡੀ ਸਕਰੀਨ ਉੱਤੇ ਨੋਟੀਫਿਕੇਸ਼ਨ ਕਿੰਝ ਵੇਖਾਈ ਦੇਣ
|
||||
Comment[pl]=Konfiguruje ustwienia powiadamiania
|
||||
Comment[pt]=Personalizar o aspeto das notificações no ecrã
|
||||
Comment[pt_BR]=Personalize como as notificações devem aparecer na sua tela
|
||||
Comment[ro]=Personalizați cum apar pe ecran notificările
|
||||
Comment[ru]=Настройка отображения оповещений на вашем экране
|
||||
Comment[sk]=Prispôsobiť spôsob upozornenia na obrazovke
|
||||
Comment[sl]=Prilagodite prikaz obvestil na zaslonu
|
||||
Comment[sq]=Përshtasni mënyrën se si shfaqen njoftimet në ekranin tuaj
|
||||
Comment[sr]=Прилагодите начин приказа обавештења на екрану
|
||||
Comment[sv]=Anpassa hur notifieringar ska visas på din skärm
|
||||
Comment[th]=กำหนดหน้าตาของการแจ้งเหตุบนหน้าจอของคุณ
|
||||
Comment[tr]=Bildirilerin görünümünü özelleştirin
|
||||
Comment[ug]=ئۇقتۇرۇشلارنىڭ كۆرۈنۈش ئۇسۇلىنى ئۆزلەشتۈر
|
||||
Comment[uk]=Налаштуйте показ сповіщень на Вашому екрані
|
||||
Comment[vi]=Tùy chỉnh cách thông báo ẩn trên màn hình
|
||||
Comment[zh_CN]=自定义通知在您屏幕上的显示方式
|
||||
Comment[zh_TW]=自訂通知該如何在您螢幕上顯示
|
||||
Exec=/usr/lib/system-notification/system-notifications.py
|
||||
TryExec=/usr/lib/system-notification/system-notifications.py
|
||||
#Icon=xfce4-notifyd
|
||||
Terminal=false
|
||||
StartupNotify=false
|
||||
Type=Application
|
||||
Categories=GTK;Settings;DesktopSettings;
|
31
system-notification/usr/lib/system-notification/system-notification.py
Executable file
31
system-notification/usr/lib/system-notification/system-notification.py
Executable file
|
@ -0,0 +1,31 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
import dbus, dbus.glib
|
||||
import gtk
|
||||
import datetime
|
||||
|
||||
systembus = dbus.SystemBus()
|
||||
sessionbus = dbus.SessionBus()
|
||||
|
||||
notifications = dbus.Interface(sessionbus.get_object('org.freedesktop.Notifications',
|
||||
'/org/freedesktop/Notifications'), 'org.freedesktop.Notifications')
|
||||
|
||||
#icon = gtk.icon_theme_get_default().lookup_icon("update-none", 22,
|
||||
# gtk.ICON_LOOKUP_USE_BUILTIN).get_filename()
|
||||
icon = '/usr/share/icons/oxygen/base/48x48/actions/svn-update.png'
|
||||
|
||||
|
||||
def notify_updates(*args):
|
||||
"""format is defined here:
|
||||
https://developer.gnome.org/notification-spec/
|
||||
convert arguments from dbus.String to normal string with str() to avoid
|
||||
errors"""
|
||||
notifications.Notify("system notification", 0, icon, "%s" % (str(args[0])),
|
||||
str(' '.join(args[1:])),
|
||||
"", {}, 0)
|
||||
|
||||
systembus.add_signal_receiver(notify_updates, 'Notification',
|
||||
'at.xundeenergie.notifications')
|
||||
|
||||
|
||||
gtk.main()
|
BIN
system-notification_0.1.3_all.deb
Normal file
BIN
system-notification_0.1.3_all.deb
Normal file
Binary file not shown.
BIN
system-notification_0.1.4_all.deb
Normal file
BIN
system-notification_0.1.4_all.deb
Normal file
Binary file not shown.
BIN
system-notification_0.1.5_all.deb
Normal file
BIN
system-notification_0.1.5_all.deb
Normal file
Binary file not shown.
1
system-notification_current_all.deb
Symbolic link
1
system-notification_current_all.deb
Symbolic link
|
@ -0,0 +1 @@
|
|||
system-notification_0.1.5_all.deb
|
Loading…
Reference in a new issue