f
This commit is contained in:
@@ -884,7 +884,11 @@ def main() -> int:
|
||||
if script_path is not None:
|
||||
default_install = repo_root
|
||||
else:
|
||||
default_install = Path.cwd() / "Medios-Macina"
|
||||
# When piped, default to home folder on POSIX, CWD on Windows
|
||||
if platform.system().lower() != "windows":
|
||||
default_install = Path.home() / "medios"
|
||||
else:
|
||||
default_install = Path.cwd() / "Medios-Macina"
|
||||
|
||||
print("\n[WEB INSTALLER MODE]")
|
||||
print(f"Current working directory: {Path.cwd()}")
|
||||
@@ -898,7 +902,9 @@ def main() -> int:
|
||||
if not install_dir_raw:
|
||||
install_path = default_install
|
||||
else:
|
||||
install_path = Path(install_dir_raw).resolve()
|
||||
# Resolve while expanding user paths (~) and environment variables ($HOME)
|
||||
expanded = os.path.expandvars(os.path.expanduser(install_dir_raw))
|
||||
install_path = Path(expanded).resolve()
|
||||
except (EOFError, KeyboardInterrupt):
|
||||
return False
|
||||
|
||||
|
||||
Reference in New Issue
Block a user