2.5 KiB
2.5 KiB
AGENTS.md
Guidance for coding agents working in this repo.
Project Shape
- This repo manages Beat Saber plugins for BSManager instances.
- Keep plugin source checkouts under
~/src/<owner>/<repo>when a locked or registry plugin has a GitHub source repo. Prefer checking out the upstream author/repo first, withoriginpointing at upstream. If the user has an existing personal fork checkout, preserve it as a remote namedgithuband set/addoriginto the upstream repo instead of replacing local work. - Prefer repo-local state for planned installs unless the task explicitly
targets the user's live default state. For mounted Windows installs, prefer
the shared Windows-partition state directory configured in
plugin-helper.local.tomlwhen both roots contain the same instance name.
Workflow Rules
- Run commands from the repo root with
PYTHONPATH=src. - A repo-local Python virtualenv is normally available at
.venv; prefer.venv/bin/pythonfor helper commands and tests when it exists. - For human-style inspection, prefer the menu with repo-local state:
PYTHONPATH=src .venv/bin/python -m plugin_helper --state-dir .state menu. - Use the helper commands instead of manually copying plugin files into an instance.
- When adding, updating, building, or investigating a GitHub-hosted plugin,
check for
~/src/<owner>/<repo>and clone the upstream repo there if it is missing. Do not substitute forks or similar repos without explicit user direction. - Treat BSIPA as a bootstrap phase:
bootstrapinstalls the locked BSIPA archive and records generated files.- ordinary plugin plans should depend on healthy bootstrap state.
- After completing repo changes, suggest a concise commit message in the final response unless the user already asked you to commit.
Validation
- Run
PYTHONPATH=src .venv/bin/python -m unittest discover -s testsafter code changes when.venvexists; otherwise usepython. - Run
PYTHONPATH=src .venv/bin/python -m compileall -q src testsfor syntax/import checks when.venvexists; otherwise usepython. - For live game validation, follow
docs/SMOKETEST.mdand tear down Beat Saber processes afterward.
Launch Notes
- BSManager may inherit Beat Saber launch arguments configured in Steam.
- Do not assume a black screen is a plugin failure until checking
Logs/_latest.log, UnityPlayer.log, and the live process command line. - Duplicate launch args such as
--no-yeet fpfc --no-yeet fpfccan trigger a fatal command-line parse error after BSIPA/plugin loading succeeds.