Skip to content

Add pre-commit hooks and update dev docs#407

Open
mahmoud wants to merge 1 commit intomasterfrom
add-precommit-devdocs
Open

Add pre-commit hooks and update dev docs#407
mahmoud wants to merge 1 commit intomasterfrom
add-precommit-devdocs

Conversation

@mahmoud
Copy link
Member

@mahmoud mahmoud commented Mar 10, 2026

  • Add .pre-commit-config.yaml with three hooks:

    • prettier: auto-formats staged frontend/src/ files
    • eslint: lints staged frontend/src/ files
    • ruff (v0.15.5): checks Python syntax errors and undefined names (E9, F63, F7, F821) in montage/
  • Add pyproject.toml with ruff line-length config

  • Update dev.md:

    • Add OAuth setup section explaining both modes (debug bypass vs real OAuth) with step-by-step registration instructions
    • Link to MediaWiki OAuth developer guide and Toolforge docs
    • Add pre-commit hooks setup section
    • Add CI section with local check commands
    • Add lint:check and format:check to frontend commands list
    • Fix Node.js version requirement (v16 -> v20)
    • Remove .env from project structure (gitignored file)
  • Update README.md:

    • Add CI badge
    • Add Development section linking to dev.md
    • Replace outdated tox instructions with Docker-based test command
    • Add Deployment section linking to deployment.md
  • Fix view_jurors -> view_juror typo in rendered_admin.py (ruff F821 caught this: route referenced view_juror but function was named view_jurors)

- Add .pre-commit-config.yaml with three hooks:
  - prettier: auto-formats staged frontend/src/ files
  - eslint: lints staged frontend/src/ files
  - ruff (v0.15.5): checks Python syntax errors and undefined names
    (E9, F63, F7, F821) in montage/

- Add pyproject.toml with ruff line-length config

- Update dev.md:
  - Add OAuth setup section explaining both modes (debug bypass vs
    real OAuth) with step-by-step registration instructions
  - Link to MediaWiki OAuth developer guide and Toolforge docs
  - Add pre-commit hooks setup section
  - Add CI section with local check commands
  - Add lint:check and format:check to frontend commands list
  - Fix Node.js version requirement (v16 -> v20)
  - Remove .env from project structure (gitignored file)

- Update README.md:
  - Add CI badge
  - Add Development section linking to dev.md
  - Replace outdated tox instructions with Docker-based test command
  - Add Deployment section linking to deployment.md

- Fix view_jurors -> view_juror typo in rendered_admin.py (ruff F821
  caught this: route referenced view_juror but function was named
  view_jurors)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant