mirror of
https://github.com/servo/servo.git
synced 2025-06-21 15:49:04 +01:00
parent
234fb68a16
commit
c160248717
1 changed files with 9 additions and 2 deletions
|
@ -55,8 +55,15 @@ def notify(elapsed):
|
|||
print("[Warning] Could not generate notification! Please make sure that the required libraries are installed!")
|
||||
|
||||
elif sys.platform.startswith('darwin'):
|
||||
# Notification code for Darwin here! For the time being printing simple msg
|
||||
print("[Warning] : Darwin System! Notifications not supported currently!")
|
||||
try:
|
||||
from distutils.spawn import find_executable
|
||||
notifier = find_executable('terminal-notifier')
|
||||
if not notifier:
|
||||
raise Exception('`terminal-notifier` not found')
|
||||
subprocess.call([notifier, '-title', 'Servo Build System',
|
||||
'-group', 'servobuild', '-message', 'Servo build complete!'])
|
||||
except:
|
||||
print("[Warning] Could not generate notification! Make sure that `terminal-notifier is installed!")
|
||||
|
||||
|
||||
@CommandProvider
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue