Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: add more linting checks #205

Merged
merged 5 commits into from
Mar 10, 2024
Merged

ci: add more linting checks #205

merged 5 commits into from
Mar 10, 2024

Conversation

voxpelli
Copy link
Member

@voxpelli voxpelli commented Mar 9, 2024

As a preparation for a PR that bumps our Node.js requirement (and as somewhat of an extraction from #204) I wanted to do this PR that extends our linting checks in three ways:

  1. It checks the formatting as part of the linting
  2. It validates that the engines.node doesn't promise more than what our dependencies does (using my installed-check)
  3. It adds knip to do all the kinds of checks that knip does. knip will also be used in eslint/eslint: chore: Introduce Knip eslint/eslint#18005

On top of that this PR also updates npm-run-all to the maintained fork (maintained by @bcomnes with occasional assistance by me) + starts using run-p to run all of the lint: jobs in parallel, to gain some speed advantage.

The installed-check script is currently set to installed-check -v -i installed-check -i npm-run-all2 -i knip as all three of those have a tighter engines.node requirement, but since all three of those are only run in linting and we don't need to run linting on older node.js versions, its okay.

The -v on the installed-check script is used to output warnings, and it outputs that currently none of the used versions of opener, rimraf and vitepress are defining an engines.version, making it impossible for installed-check to verify if they are inside or outside of our engines.node.

@voxpelli voxpelli requested a review from a team March 9, 2024 12:01
@voxpelli voxpelli self-assigned this Mar 9, 2024
Helps configure the very basics of editors in a way that conforms to the desired formatting – like indention width
@voxpelli
Copy link
Member Author

voxpelli commented Mar 9, 2024

Updated to also include an .editorconfig, to avoid the most basic of formatting inconsistencies. See also eslint-community/eslint-plugin-n#126 (which I copied this config from)

Copy link
Member

@ota-meshi ota-meshi left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks!

@voxpelli voxpelli merged commit 6a7a3f3 into main Mar 10, 2024
14 checks passed
@voxpelli voxpelli deleted the extended-checks branch March 10, 2024 11:10
Copy link

🎉 This PR is included in version 4.4.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants