# pm3py venv activation with mode-based auto-imports.
# Usage: source activate           — core (Proxmark3, Cmd, etc.)
#        source activate sim       — + SimSession, transponder models
#        source activate sniff     — + SniffSession, trace decoders
#        source activate all       — everything
#
# Then:  python    — REPL with auto-imports
#        ipython   — IPython with auto-imports (if installed)

# Activate the venv
source "$(dirname "${BASH_SOURCE[0]}")/.venv/bin/activate"

# Set mode and PYTHONSTARTUP
export PM3PY_MODE="${1:-core}"
export PYTHONSTARTUP="$(dirname "${BASH_SOURCE[0]}")/.pythonstartup.py"

# Update prompt to show mode
PS1="(pm3py:${PM3PY_MODE}) ${_OLD_VIRTUAL_PS1:-\$ }"
export PS1

echo "pm3py env ready (mode: ${PM3PY_MODE}). Run 'python' for REPL with auto-imports."
