-
Notifications
You must be signed in to change notification settings - Fork 288
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
Add lint #956
Add lint #956
Conversation
This pull request has been deployed to Vercel. Latest commit: e62f20c ✅ Preview: https://iota-wiki-1x2b5zq1z-iota1.vercel.app |
This pull request has been deployed to Vercel. Latest commit: 63d975e ✅ Preview: https://iota-wiki-1ysko9ywz-iota1.vercel.app |
This pull request has been deployed to Vercel. Latest commit: 859df35 ✅ Preview: https://iota-wiki-1nofhwl5b-iota1.vercel.app |
This pull request has been deployed to Vercel. Latest commit: 8c80ee3 ✅ Preview: https://iota-wiki-76cs9bjx3-iota1.vercel.app |
Updated this PR. You can now run As a test I suggest to run: yarn
cd cli
yarn && yarn build
cd -
yarn lint:md iota/**/*.{md,mdx} |
@jlvandenhout wdyt, should I also run the linter once and fix everything? |
I'd wait for the merge. I'm sure most errors are simple to fix, but it makes no sense to me to fix them in the current model which is much more complex than the merge. |
Seems like this still contains bugs with the expansion of glob patterns. But on linux |
Using Ubuntu 22.04.2 LTS, 64 bit, on Intel® Core™ i7-10750H CPU @ 2.60GHz × 12 I had no issues. I've attached the log file. |
There is way to many stuff to fix. And as a lot of it is in deprecated docs, we can either:
|
I think merging and following up with one PR to remove (or archive) deprecated docs and another to fix the issues may make this easier to track, and we'd have a clearer scope for each PR. WDYT? |
Yeah, I prefer that too. So that means this PR is ready for review and merge ;) |
Co-authored-by: Jeroen van den Hout <[email protected]>
Co-authored-by: Jeroen van den Hout <[email protected]>
Description of change
Added markdownlint-cli2 to our cli. So now you can run
yarn iota-wiki lint glob0 [glob1] [...] [globN]
to lint the corresponding files. The command comes with a custom config.You can override the config by having a file following the .markdownlint-cli2.cjs syntax and running the command with
yarn iota-wiki lint -c custom-lint.cjs glob0 [glob1] [...] [globN]
Open Questions:
Would it be possible to just use a link for the default config? That way we could just change the default file and wouldn't need a new cli release. Does that even make sense?
We need to think about a first default config we want to provide. I tested with wallet.rs and came up with this config:
Although I'm not sure if it makes sense to add the rule
MD033
config, because if there are other custom components to ignore the whole array needs to be overridden anyway. And I guess we have custom components in basically all repos.Links to any relevant issues
Fixes #830
Type of change
Change checklist