mirror of
https://github.com/onyx-and-iris/voicemeeter-api-python.git
synced 2024-11-15 16:40:46 +00:00
issue where subprocess not inheriting virtual env
see SO python-subprocess-doesnt-inherit-virtual-environment
This commit is contained in:
parent
c1e23ab250
commit
7732a26c40
29
scripts.py
29
scripts.py
@ -1,40 +1,41 @@
|
|||||||
import subprocess
|
import subprocess
|
||||||
|
import sys
|
||||||
from pathlib import Path
|
from pathlib import Path
|
||||||
|
|
||||||
|
|
||||||
def ex_dsl():
|
def ex_dsl():
|
||||||
path = Path.cwd() / "examples" / "dsl" / "."
|
scriptpath = Path.cwd() / "examples" / "dsl" / "."
|
||||||
subprocess.run(["py", str(path)])
|
subprocess.run([sys.executable, str(scriptpath)])
|
||||||
|
|
||||||
|
|
||||||
def ex_events():
|
def ex_events():
|
||||||
path = Path.cwd() / "examples" / "events" / "."
|
scriptpath = Path.cwd() / "examples" / "events" / "."
|
||||||
subprocess.run(["py", str(path)])
|
subprocess.run([sys.executable, str(scriptpath)])
|
||||||
|
|
||||||
|
|
||||||
def ex_gui():
|
def ex_gui():
|
||||||
path = Path.cwd() / "examples" / "gui" / "."
|
scriptpath = Path.cwd() / "examples" / "gui" / "."
|
||||||
subprocess.run(["py", str(path)])
|
subprocess.run([sys.executable, str(scriptpath)])
|
||||||
|
|
||||||
|
|
||||||
def ex_levels():
|
def ex_levels():
|
||||||
path = Path.cwd() / "examples" / "levels" / "."
|
scriptpath = Path.cwd() / "examples" / "levels" / "."
|
||||||
subprocess.run(["py", str(path)])
|
subprocess.run([sys.executable, str(scriptpath)])
|
||||||
|
|
||||||
|
|
||||||
def ex_midi():
|
def ex_midi():
|
||||||
path = Path.cwd() / "examples" / "midi" / "."
|
scriptpath = Path.cwd() / "examples" / "midi" / "."
|
||||||
subprocess.run(["py", str(path)])
|
subprocess.run([sys.executable, str(scriptpath)])
|
||||||
|
|
||||||
|
|
||||||
def ex_obs():
|
def ex_obs():
|
||||||
path = Path.cwd() / "examples" / "obs" / "."
|
scriptpath = Path.cwd() / "examples" / "obs" / "."
|
||||||
subprocess.run(["py", str(path)])
|
subprocess.run([sys.executable, str(scriptpath)])
|
||||||
|
|
||||||
|
|
||||||
def ex_observer():
|
def ex_observer():
|
||||||
path = Path.cwd() / "examples" / "observer" / "."
|
scriptpath = Path.cwd() / "examples" / "observer" / "."
|
||||||
subprocess.run(["py", str(path)])
|
subprocess.run([sys.executable, str(scriptpath)])
|
||||||
|
|
||||||
|
|
||||||
def test():
|
def test():
|
||||||
|
Loading…
Reference in New Issue
Block a user