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

chore: use markdownlint to lint the docs #26792

Merged
merged 2 commits into from Jan 14, 2021
Merged

Conversation

@dsanders11
Copy link
Contributor

@dsanders11 dsanders11 commented Dec 2, 2020

Description of Change

Use markdownlint to lint the docs and help keep them tidier going forward. markdownlint from DavidAnson/markdownlint, not to be confused with the markdownlint/markdownlint repo.

It's actively maintained, highly configurable, has integration with editors like VS Code, and other tooling support like GitHub problem matchers.

I've been making PRs to clean up the markdown, and the configuration in this PR is tailored to run cleanly with the current state of the docs. A couple of the rules off in this config may want to be turned on in the future (for example, no-duplicate-header - duplicate headers cause problems for linking since they're multiple places on the page), but I think it's a reasonable compromise for now. Line length is disabled for now; although the style guide says wrap at 80 characters, there's a lot of violations in the docs currently, and I don't want to wrestle with that.

PR also drops script/check-trailing-whitespace.py since markdownlint can provide that functionality. I don't love needing the second config file to get the Git hooks functionality, but I didn't want to switch on autofixing more complex rules, and they didn't want to take a PR to specify rules to fix on the CLI, so it was the only way to be a drop-in replacement.

The autofix config can be expanded to include rules like blank lines, but for the initial PR I've aimed to be no changes from the current behavior.

Runs clean, but some changes slipped in before I opened this PR, so #26793 needs to be merged first to unblock this.

Checklist

  • PR description included and stakeholders cc'd

Release Notes

Notes: none

@dsanders11 dsanders11 mentioned this pull request Dec 2, 2020
1 of 1 task complete
@dsanders11 dsanders11 force-pushed the dsanders11:markdownlint branch from 164daaa to 92b0c62 Dec 2, 2020
@electron-cation electron-cation bot removed the new-pr 🌱 label Dec 9, 2020
@miniak
miniak approved these changes Dec 16, 2020
@zcbenz zcbenz force-pushed the dsanders11:markdownlint branch from 92b0c62 to d2f88e0 Jan 14, 2021
@zcbenz zcbenz added the semver/none label Jan 14, 2021
@zcbenz
zcbenz approved these changes Jan 14, 2021
@zcbenz zcbenz merged commit 63ca878 into electron:master Jan 14, 2021
8 of 10 checks passed
8 of 10 checks passed
build-mac Workflow: build-mac
Details
appveyor: win-x64-testing-pr Waiting for AppVeyor build to complete
Details
Artifact Comparison No Changes
Details
Semantic Pull Request ready to be squashed
Details
Semver Label Enforcement Found "semver/none"
Details
WIP Ready for review
Details
appveyor: win-ia32-testing-pr AppVeyor build succeeded
Details
build-linux Workflow: build-linux
Details
lint Workflow: lint
Details
release-notes Release notes found
@release-clerk
Copy link

@release-clerk release-clerk bot commented Jan 14, 2021

No Release Notes

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

Successfully merging this pull request may close these issues.

None yet

3 participants
You can’t perform that action at this time.