ci / macos-latest / py3.12 (push) Canceled after 0s
ci / macos-latest / py3.9 (push) Canceled after 0s
ci / ubuntu-latest / py3.12 (push) Canceled after 0s
ci / ubuntu-latest / py3.9 (push) Canceled after 0s
ci / windows-latest / py3.12 (push) Canceled after 0s
ci / windows-latest / py3.9 (push) Canceled after 0s
- remove lab/ (index.php, apache conf, up/down/status shims) - remove poc/lab.py and the 'poc lab' subcommand - proof path defaults to a fixed per-user dir so the working directory no longer matters - README: target recipe documented instead of shipped
16 lines
429 B
Python
16 lines
429 B
Python
import os
|
|
|
|
|
|
def default_outdir():
|
|
if os.name == "nt":
|
|
base = os.environ.get("LOCALAPPDATA") or os.path.expanduser(os.path.join("~", "AppData", "Local"))
|
|
else:
|
|
base = os.environ.get("XDG_DATA_HOME") or os.path.expanduser(os.path.join("~", ".local", "share"))
|
|
return os.path.join(base, "php2shell", "out")
|
|
|
|
|
|
def ensure():
|
|
path = default_outdir()
|
|
os.makedirs(path, exist_ok=True)
|
|
return path
|