mirror of
https://github.com/maglore9900/max_headroom.git
synced 2025-06-04 10:30:24 +00:00
16 lines
448 B
Python
16 lines
448 B
Python
import time
|
|
from plyer import notification
|
|
|
|
def start_timer(seconds):
|
|
seconds = int(seconds) # Convert to integer
|
|
print(f"Timer started for {seconds} seconds...")
|
|
time.sleep(seconds) # Sleep for the desired time
|
|
notification.notify(
|
|
title="Timer Finished",
|
|
message="Your time is up!",
|
|
timeout=10 # Notification will disappear after 10 seconds
|
|
)
|
|
|
|
# Example: Set a timer for 60 seconds
|
|
# start_timer(5)
|