# PyGhidra Crusader Toolkit This toolkit drives the local PyGhidra fallback workflow for the Crusader Ghidra project. ## Defaults - Ghidra install dir: `I:\Apps\ghidra_12.0.4_PUBLIC` - Python env: `.venv-pyghidra311` - Python base interpreter: `C:\Users\Maddo\.pyenv\pyenv-win\versions\3.11.6\python.exe` - CLI entrypoint: `.\.venv-pyghidra311\Scripts\python.exe -m tools.pyghidra_crusader` ## Bootstrap Or Refresh Run this from the repo root to create or refresh the local environment against the bundled Ghidra 12.0.4 offline packages: ```powershell powershell -ExecutionPolicy Bypass -File .\tools\pyghidra_crusader\bootstrap_env.ps1 ``` The script recreates or refreshes `.venv-pyghidra311`, then installs these pinned packages from the local Ghidra tree: - `pyghidra==3.0.2` from `Ghidra\Features\PyGhidra\pypkg\dist` - `ghidra-stubs==12.0.4` from `docs\ghidra_stubs` Override the defaults when needed: ```powershell powershell -ExecutionPolicy Bypass -File .\tools\pyghidra_crusader\bootstrap_env.ps1 ` -PythonExe C:\Path\To\python.exe ` -GhidraInstallDir I:\Apps\ghidra_12.0.4_PUBLIC ` -VenvPath .\.venv-pyghidra311 ``` ## Validation After bootstrap, validate package versions and the project-open path: ```powershell .\.venv-pyghidra311\Scripts\python.exe -m tools.pyghidra_crusader project-files ``` If you need to target a different installed Ghidra tree temporarily, set `GHIDRA_INSTALL_DIR` or pass `--install-dir` to the CLI.