mirror of
https://github.com/ProjectLeonida/mandy.git
synced 2026-12-06 22:38:39 +00:00
Linux and macOS had no one-command entry point: Build.bat and Mods.bat are cmd.exe scripts. Build.sh and Mods.sh find Python 3.12 or newer (the versioned python3.N first, since a distribution's python3 can be older) and run make_game.py or the mod manager's window with -I, passing every argument through. They install and download nothing. tests/test_shell_launchers.py runs both against stub interpreters on a private PATH. The mod manager's missing-Tkinter message now names the distribution package off Windows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
14 lines
788 B
Bash
Executable File
14 lines
788 B
Bash
Executable File
#!/bin/sh
|
|
# Linux and macOS counterpart of Mods.bat: opens the mod manager window (tools/leonida_mods.py gui). It manages
|
|
# <port>/mods and never touches the game package. The window needs Tkinter (Debian and Ubuntu: python3-tk).
|
|
here=$(CDPATH='' cd -- "$(dirname -- "$0")" && pwd) || exit 1
|
|
for py in python3.14 python3.13 python3.12 python3 python; do
|
|
command -v "$py" >/dev/null 2>&1 || continue
|
|
if "$py" -c 'import sys; sys.exit(0 if sys.version_info >= (3, 12) else 1)' >/dev/null 2>&1; then
|
|
exec "$py" -I "$here/tools/leonida_mods.py" gui "$@"
|
|
fi
|
|
done
|
|
echo "Python 3.12 or newer is needed. Install it with your package manager (Debian and Ubuntu:" >&2
|
|
echo "sudo apt install python3 python3-tk; macOS: brew install python), then run ./Mods.sh again." >&2
|
|
exit 1
|