beepmeup 0.1.0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
beepmeup/__init__.py
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
from .beepmeup import beep
|
beepmeup/beepmeup.py
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import platform
|
|
2
|
+
import subprocess
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
def beep(frequency=440, duration=500):
|
|
6
|
+
system = platform.system()
|
|
7
|
+
|
|
8
|
+
if system == "Windows":
|
|
9
|
+
import winsound
|
|
10
|
+
winsound.Beep(frequency, duration)
|
|
11
|
+
|
|
12
|
+
elif system == "Linux":
|
|
13
|
+
subprocess.run(["beep", "-f", str(frequency), "-l", str(duration)],
|
|
14
|
+
check=False)
|
|
15
|
+
|
|
16
|
+
elif system == "Darwin": # Mac
|
|
17
|
+
# frequency und duration werden hier ignoriert, afplay spielt eine Audiodatei
|
|
18
|
+
subprocess.run(["afplay", "/System/Library/Sounds/Ping.aiff"],
|
|
19
|
+
check=False)
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
beepmeup/__init__.py,sha256=eGnPoyWY6CDW16hhjklNMVPZonHggmVbeoFJ6m1DeO8,26
|
|
2
|
+
beepmeup/beepmeup.py,sha256=b6gW982BGMyBDHGdkbcqd53dU5O9Or8G1QWpCBm6M54,590
|
|
3
|
+
beepmeup-0.1.0.dist-info/METADATA,sha256=HyxUgvzxf_517x6pEn9wJNRaNbxf27J3JYhAJCXgdzw,241
|
|
4
|
+
beepmeup-0.1.0.dist-info/WHEEL,sha256=aeYiig01lYGDzBgS8HxWXOg3uV61G9ijOsup-k9o1sk,91
|
|
5
|
+
beepmeup-0.1.0.dist-info/top_level.txt,sha256=TvN8aaX9Z8HHmZYZ4bRqdyvLcLSbEJEgoYreWHnFVCM,9
|
|
6
|
+
beepmeup-0.1.0.dist-info/RECORD,,
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
beepmeup
|