Created
March 11, 2019 14:04
-
-
Save jwilson8767/8b831142969f1468bee28e7e7399d239 to your computer and use it in GitHub Desktop.
Beep for WSL
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def beep(): | |
# try to use windows sound to beep | |
try: | |
import winsound | |
winsound.PlaySound('SystemQuestion', winsound.SND_ALIAS) | |
except ImportError: | |
pass | |
# usually works on unix systems | |
print('\a') |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment