diff --git a/README.md b/README.md index f852159..f7bcde4 100644 --- a/README.md +++ b/README.md @@ -12,9 +12,14 @@ This is Light weight mail notifier written in PyQt5. It checks your mailbox peri ![MailboxFull](https://raw.github.com/rinaldus/mail-notifier/master/screenshots/screen2.jpg) ![Settings](https://raw.github.com/rinaldus/mail-notifier/master/screenshots/screen3.jpg) +## System requirements + - Python 3 + - PyQt5 + - *(after version 3.01)* [notify2](https://pypi.python.org/pypi/notify2) library + ## Install -You need to install PyQt5 as dependency. Then just clone this git repository or download release and copy all files where you want to store this program. No additional installation is required. +Just clone this git repository or download release and copy all files where you want to store this program. No additional installation is required. *In version 0.10 you also need to edit mail-notifier.py and fill your mailbox credentials in 70-72 rows* ## Launch diff --git a/mail-notifier.py b/mail-notifier.py index 657b64a..5089962 100755 --- a/mail-notifier.py +++ b/mail-notifier.py @@ -18,11 +18,13 @@ from PyQt5 import QtCore, QtGui, QtWidgets import os import socket import time +import notify2 from datetime import datetime, date, time #variables programTitle = "Mail Notifier" -programVersion = "3.01" +programVersion = "3.01-dev" +notify2.init(programTitle) settings = QSettings(os.path.expanduser("~")+"/.config/mail-notifier/settings.conf", QSettings.NativeFormat) def GlobalSettingsExist(): if ((settings.contains("CheckInterval") and settings.value("CheckInterval") != "") and @@ -439,7 +441,8 @@ def mail_check(): window.lastCheckCount = mail_count def notify(message): if settings.value("Notify"): - subprocess.Popen(['notify-send', programTitle, message]) + n = notify2.Notification(programTitle, message) + n.show() return