Files
minecraft-bot/run_connect.sh
T

20 lines
498 B
Bash
Executable File

#!/bin/bash
set -euo pipefail
cd "$(dirname "$0")"
if ! command -v uv >/dev/null 2>&1; then
echo "Install uv to create the local Python environment." >&2
exit 1
fi
if [ ! -x .venv/bin/python ]; then
uv venv .venv
fi
uv pip install --python .venv/bin/python -e ../pyCraft
export SERVER="${SERVER:-games.protospace.ca}"
export PORT="${PORT:-25565}"
export PLAYER_NAME="${PLAYER_NAME:-mosfet1}"
export GAME_PASSWORD="${GAME_PASSWORD:-mosfetbot}"
exec .venv/bin/python -m mosfet.connect