This repository was archived by the owner on Nov 30, 2022. It is now read-only.
Open
Show file tree
Hide file tree
Changes from all commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Failed to load files.
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
import sys
import time
import pyjokes
import schedule
from notifypy import Notify


def job():
notification = Notify()
notification.title = "Funny Joke"
notification.message = pyjokes.get_joke()
notification.send()


def run_forever():
while True:
schedule.run_pending()
time.sleep(1)


schedule.every(30).minutes.do(job)


if __name__ == '__main__':
try:
job()
run_forever()
except KeyboardInterrupt:
print("GoodBye!")
sys.exit(0)

Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
notify-py==0.3.0
pyjokes==0.6.0
schedule==0.6.0