Skip to content

Instantly share code, notes, and snippets.

@jwilson8767
Created March 11, 2019 14:04
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jwilson8767/8b831142969f1468bee28e7e7399d239 to your computer and use it in GitHub Desktop.
Save jwilson8767/8b831142969f1468bee28e7e7399d239 to your computer and use it in GitHub Desktop.
Beep for WSL
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