Skip to content

Fix: CI Javascript Lint Test#480

Merged
Volte6 merged 6 commits intoGoMudEngine:masterfrom
clabs-public-forks:fix/ci-lint-test
Apr 16, 2026
Merged

Fix: CI Javascript Lint Test#480
Volte6 merged 6 commits intoGoMudEngine:masterfrom
clabs-public-forks:fix/ci-lint-test

Conversation

@CaseyLabs
Copy link
Copy Markdown
Collaborator

@CaseyLabs CaseyLabs commented Apr 16, 2026

Description

  • Simplify JavaScript linting in CI by routing the workflow through make js-lint.
  • Limit JSHint to the maintained frontend files so unrelated or vendored scripts do not block PRs.
  • Move the linting runtime from Node 20 to Node 22 so the repo stays on a currently supported LTS line.

Why

  • Keep CI strict on the frontend code this repo actively maintains, without failing unrelated changes because of sample or third-party assets.
  • Keep local and GitHub Actions linting on a supported Node LTS baseline for future contributors.

Changes

  • Update .github/workflows/lint.yml to run make js-lint and use Node 22.
  • Scope make js-lint in the Makefile to the maintained webclient and admin JavaScript paths.
  • Update the Docker-based lint command in the Makefile from node:20 to node:22.
  • Adjust .jshintrc for the browser-oriented frontend code and suppress the warnings used by these maintained scripts.
  • Add the required /* global */ declarations in the affected frontend files, including window-gametime.js and window-map.js, so the lint step passes without changing runtime behavior.

Validation

  • make js-lint

@CaseyLabs CaseyLabs changed the title Fix: Relax CI Lint Test Fix: CI Javascript Lint Test Apr 16, 2026
@CaseyLabs CaseyLabs marked this pull request as ready for review April 16, 2026 19:58
@CaseyLabs CaseyLabs requested a review from Volte6 as a code owner April 16, 2026 19:58
Copy link
Copy Markdown
Member

@Volte6 Volte6 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

JS linting should also check scripts defined in the _datafiles folder and nested folders. That's actually the primary purpose of the js linting - to make sure the scripts won't break when they are dynamically loaded/executed.

@CaseyLabs
Copy link
Copy Markdown
Collaborator Author

Updated make js-lint to lint every *.js file under _datafiles recursively, including nested world/sample scripts. Verified with make js-lint.

@Volte6 Volte6 merged commit e24c7dd into GoMudEngine:master Apr 16, 2026
3 checks passed
@CaseyLabs CaseyLabs deleted the fix/ci-lint-test branch April 16, 2026 21:58
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.

2 participants