Skip to content

Commit bbd7bf3

Browse files
committed
docs: scope userscripts guidelines to userscripts/AGENTS.md and keep root AGENTS.md repo-wide
1 parent 1844741 commit bbd7bf3

2 files changed

Lines changed: 19 additions & 11 deletions

File tree

‎AGENTS.md‎

Lines changed: 2 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -6,20 +6,11 @@
66
```bash
77
userscripts/venv/bin/pytest
88
```
9-
- Run only userscript end-to-end tests:
10-
```bash
11-
userscripts/venv/bin/pytest userscripts/
12-
```
139
- Run only Python tests:
1410
```bash
1511
userscripts/venv/bin/pytest python/
1612
```
17-
- Verify userscript JavaScript syntax before committing:
13+
- Run only Userscript tests:
1814
```bash
19-
node --check userscripts/<project>/<name>.user.js
15+
userscripts/venv/bin/pytest userscripts/
2016
```
21-
22-
## Versioning & Git Commits
23-
24-
- Do not manually increment userscript patch `@version` headers for routine changes; the `.git/hooks/pre-commit` hook (`userscripts/bump_version_precommit.py`) automatically increments patch numbers on staged `*.user.js` files and synchronizes adjacent `README.md` install links.
25-
- When committing changes touching userscripts, ensure write access is permitted for pre-commit hook execution.

‎userscripts/AGENTS.md‎

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,17 @@
1+
# Userscripts Agent Guidelines
2+
3+
## Testing & Verification
4+
5+
- Run userscript end-to-end browser tests using the shared virtualenv:
6+
```bash
7+
userscripts/venv/bin/pytest userscripts/
8+
```
9+
- Verify JavaScript syntax before committing:
10+
```bash
11+
node --check userscripts/<project>/<name>.user.js
12+
```
13+
14+
## Versioning & Git Commits
15+
16+
- Do not manually increment userscript patch `@version` headers for routine changes; the `.git/hooks/pre-commit` hook (`userscripts/bump_version_precommit.py`) automatically increments patch numbers on staged `*.user.js` files and synchronizes adjacent `README.md` install links.
17+
- When committing changes touching userscripts, ensure write access is permitted for pre-commit hook execution.

0 commit comments

Comments
 (0)