-
Notifications
You must be signed in to change notification settings - Fork 49
Add spellcheck and URI link validation on Markdown files in tests #211
Comments
All for this! Not sure if it can be applied here, but this also have npm packages. For spell checking I use Code Spell Checker in Visual Studio Code which uses cspell. Mostly because it has dictionaries for several languages (source), even Swedish 😍. It can test the code as well, like comment-based help and variables. Although I have a massive list of exclusions. |
Looking at the MarkdownLinkCheck module, it seems it very outdated. The source Markdig is on version 0.15.1 now; https://github.com/lunet-io/markdig#download. Looking at the change log it feels that we want to use a newer version. |
I bumped MarkdownLinkCheck to use 0.15.1 Markdig and published it as 0.2.0 |
@vors many thanks for updating the module for us! 😃 |
Looking at the spellchecker. Running that in for example SqlServerDsc it generates a lot of spelling errors because it does not recognize a lot of word that are specific to the module. But those are easy added to the
.spelling
|
If cSpell is used for spelling, then the same configuration file can be used for the VSCode extension "Code Spell Checker". Also, the output of cSpell looked easier to parse, or rather, no need to parse it. No errors:
Errors:
Install:
.vscode/cSpell.json (stripped version of the config file used for SqlServerDsc): {
"ignorePaths": [
".git",
".vscode"
],
"language": "en",
"dictionaries": [
"powershell"
],
"words": [
"Addnode"
],
"ignoreRegExpList": [
"/windowsservercore/g",
"/SQLPS/g",
"/AppVeyor/g"
]
} |
@vors Tried MarkdownLinkCheck, and it finds broken links in my tests, but there are one issue, do you know if it can be solved (easily)? The issue is that it seems to think a correct link that points to a folder is broken. For example it fails on all the links in the README.md here. https://github.com/PowerShell/SqlServerDsc/tree/dev/Examples
|
Opened issue vors/MarkdownLinkCheck#5 for previous comment. |
- Add new opt-in common test for markdown link linting (issue PowerShell#211).
- Add new opt-in common test for markdown link linting (issue PowerShell#211).
- Add new opt-in common test for markdown link linting (issue PowerShell#211).
Markdown link linting is proposed in PR #273. Looking at adding spell check when I have time. |
- Adding opt-in common test for spellchecking markdown files. Opt-in by adding "Common Tests - Spellcheck Markdown Files" in the file .MetaTestOptIn.json (issue PowerShell#211).
- Adding opt-in common test for spellchecking markdown files. Opt-in by adding "Common Tests - Spellcheck Markdown Files" in the file .MetaTestOptIn.json (issue PowerShell#211).
- Adding opt-in common test for spellchecking markdown files. Opt-in by adding "Common Tests - Spellcheck Markdown Files" in the file .MetaTestOptIn.json (issue PowerShell#211).
- Adding opt-in common test for spellchecking markdown files. Opt-in by adding "Common Tests - Spellcheck Markdown Files" in the file .MetaTestOptIn.json (issue PowerShell#211).
Issue vors/MarkdownLinkCheck#5 is closed, I did not use relative path - made a review comment so we can add that to the docs. |
Added PR #279 for spell-checking, although there is currently a problem with using cSpell, it sends output to stderr even when there is no error, submitted issue streetsidesoftware/cspell#61. |
- Adding opt-in common test for spellchecking markdown files. Opt-in by adding "Common Tests - Spellcheck Markdown Files" in the file .MetaTestOptIn.json (issue PowerShell#211).
- Add new opt-in common test for markdown link linting (issue PowerShell#211).
- Adding opt-in common test for spellchecking markdown files. Opt-in by adding "Common Tests - Spellcheck Markdown Files" in the file .MetaTestOptIn.json (issue PowerShell#211).
- Adding opt-in common test for spellchecking markdown files. Opt-in by adding "Common Tests - Spellcheck Markdown Files" in the file .MetaTestOptIn.json (issue PowerShell#211).
- Add new opt-in common test for markdown link linting (issue PowerShell#211).
- Adding opt-in common test for spellchecking markdown files. Opt-in by adding "Common Tests - Spellcheck Markdown Files" in the file .MetaTestOptIn.json (issue PowerShell#211).
- Add new opt-in common test for markdown link linting (issue PowerShell#211).
- Adding opt-in common test for spellchecking markdown files. Opt-in by adding "Common Tests - Spellcheck Markdown Files" in the file .MetaTestOptIn.json (issue PowerShell#211).
- Add new opt-in common test for markdown link linting (issue PowerShell#211).
- Add new opt-in common test for markdown link linting (issue PowerShell#211).
- Add new opt-in common test for markdown link linting (issue PowerShell#211).
- Add new opt-in common test for markdown link linting (issue #211).
- Adding opt-in common test for spellchecking markdown files. Opt-in by adding "Common Tests - Spellcheck Markdown Files" in the file .MetaTestOptIn.json (issue PowerShell#211).
To help improve the quality of the MD files in the DSC Resource Kit, we could add tests for spelling and URI link validation. As per discussion with @vors here.
These look like they could be added pretty easily. We'd want to use the "Opt-in" model for this like most tests.
The text was updated successfully, but these errors were encountered: