Skip to content

Commit 3eb80e8

Browse files
gukoffKonstantin GukovTessFerrandez
authored
Change markdown link checker to lychee (#1078)
* Scaffold lychee instead of markdown-link-check * fix bad links * Remove another linkcheck solution * Switch documentation from markdownlinkcheck to lychee * Fix 2 more links * Ignore another link * Remove megalinter args for MARKDOWN_MARKDOWN_LINK_CHECK * Add "lycheeverse" do .cspell --------- Co-authored-by: Konstantin Gukov <konstantin.gukov@microsoft.com> Co-authored-by: Tess Ferrandez <tferrand@microsoft.com>
1 parent 47f00bb commit 3eb80e8

File tree

16 files changed

+147
-120
lines changed

16 files changed

+147
-120
lines changed

.cspell.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -244,6 +244,7 @@
244244
"logissue",
245245
"longrunning",
246246
"Loukides",
247+
"lycheeverse",
247248
"makedirs",
248249
"Margit",
249250
"markdig",

.github/workflows/mega-linter.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ jobs:
3030
steps:
3131
# Git Checkout
3232
- name: Checkout Code
33-
uses: actions/checkout@v3
33+
uses: actions/checkout@v4
3434
with:
3535
token: ${{ secrets.GITHUB_TOKEN }}
3636
fetch-depth: 0
@@ -39,8 +39,8 @@ jobs:
3939
- name: MegaLinter
4040
id: ml
4141
# You can override MegaLinter flavor used to have faster performances
42-
# More info at https://oxsecurity.github.io/megalinter/flavors/
43-
uses: oxsecurity/megalinter@v7.1.0
42+
# More info at https://megalinter.io/latest/flavors/
43+
uses: oxsecurity/megalinter@v8.1.0
4444
env:
4545
# All available variables are described in documentation
4646
# https://megalinter.io/latest/config-file/

.gitignore

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,9 @@
33
##
44
## Get latest from https://github.com/github/gitignore/blob/master/VisualStudio.gitignore
55

6+
# Lychee link checker
7+
.lycheecache
8+
69
# User-specific files
710
*.suo
811
*.user

.markdown-link-check.json

Lines changed: 0 additions & 17 deletions
This file was deleted.

.mega-linter.yml

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -12,17 +12,13 @@ ENABLE_LINTERS:
1212
- SPELL_CSPELL
1313
- YAML_PRETTIER
1414
- YAML_YAMLLINT
15-
- MDLINKCHECK_LINKCHECK
15+
- SPELL_LYCHEE
1616

1717
SPELL_CSPELL_DISABLE_ERRORS: true
18-
MARKDOWN_MARKDOWN_LINK_CHECK_DISABLE_ERRORS: true
1918
SHOW_ELAPSED_TIME: true
2019
FILEIO_REPORTER: false
2120
PARALLEL: true
2221
GITHUB_STATUS_REPORTER: true
2322
LOG_LEVEL: WARNING
24-
MARKDOWN_MARKDOWN_LINK_CHECK_ARGUMENTS: "-q"
2523
MARKDOWN_MARKDOWN_TABLE_FORMATTER_ARGUMENTS: "-c"
2624
# DISABLE_ERRORS: true # Uncomment if you want MegaLinter to detect errors but not block CI to pass
27-
PLUGINS:
28-
- https://raw.githubusercontent.com/shiranr/linkcheck/v2.0.20.changed_files/mega-linter-plugin-linkcheck/linkcheck.megalinter-descriptor.yml

CONTRIBUTING.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ When this occurs, do the following
7878
1. Verify that the link is OK, if it redirects, change the path to be the final link.
7979
1. If the link is not ok, fix the link (even if it is not in your document) if you find a good equivalent link. If you can't find a good equivalent link, contact one of the [maintainers](#maintainers) for a solution.
8080
1. Re-run the job, or ask to have the job re-run (if you are a first time contributor). Sometimes the link checker fails due to temporary connectivity issues.
81-
1. If the link checker still fails, and you have confirmed that the link is ok, exclude the link from checking, in the `.markdownlinkcheck.json` file in the root of the repository.
81+
1. If the link checker still fails, and you have confirmed that the link is ok, exclude the link from checking in the [lychee.toml](./lychee.toml) file.
8282

8383
## Running Locally (*Remotely*)
8484

@@ -96,7 +96,7 @@ For any questions or concerns, please contact [Tess Ferrandez](https://github.co
9696

9797
## Legal Notices
9898

99-
Microsoft and any contributors grant you a license to the Microsoft documentation and other content in this repository under the [Creative Commons Attribution 4.0 International Public License](https://creativecommons.org/licenses/by/4.0/legalcode), see the [LICENSE](LICENSE) file, and grant you a license to any code in the repository under the [MIT License](https://opensource.org/licenses/MIT), see the [LICENSE-CODE](LICENSE-CODE) file.
99+
Microsoft and any contributors grant you a license to the Microsoft documentation and other content in this repository under the [Creative Commons Attribution 4.0 International Public License](https://creativecommons.org/licenses/by/4.0/legalcode), see the [LICENSE](LICENSE) file, and grant you a license to any code in the repository under the [MIT License](https://opensource.org/license/MIT), see the [LICENSE-CODE](LICENSE-CODE) file.
100100

101101
Microsoft, Windows, Microsoft Azure and/or other Microsoft products and services referenced in the documentation may be either trademarks or registered trademarks of Microsoft in the United States and/or other countries. The licenses for this project do not grant you rights to use any Microsoft
102102
names, logos, or trademarks. Microsoft's general trademark guidelines can be found at <https://www.microsoft.com/en-us/legal/intellectualproperty/trademarks>.

docs/CI-CD/continuous-integration.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -171,12 +171,12 @@ Implementing schema validation is divided in two - the generation of the schemas
171171

172172
There are two options to generate a schema:
173173

174-
- [From code](https://json-schema.org/implementations.html#from-code) - we can leverage the existing models and objects in the code and generate a customized schema.
175-
- [From data](https://json-schema.org/implementations.html#from-data) - we can take yaml/json samples which reflect the configuration in general and use the various online tools to generate a schema.
174+
- [From code](https://json-schema.org/tools?query=#code-to-schema) - we can leverage the existing models and objects in the code and generate a customized schema.
175+
- [From data](https://json-schema.org/tools?query=#data-to-schema) - we can take yaml/json samples which reflect the configuration in general and use the various online tools to generate a schema.
176176

177177
### Validation
178178

179-
The schema has 30+ [validators](https://json-schema.org/implementations.html#validators) for different languages, including 10+ for JavaScript, so no need to code it yourself.
179+
The schema has 30+ [validators](https://json-schema.org/tools?query=#validator) for different languages, including 10+ for JavaScript, so no need to code it yourself.
180180

181181
## Integration Validation
182182

docs/CI-CD/recipes/ci-pipeline-for-better-documentation.md

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,7 @@ This pipeline helps address that!
1313
The pipeline uses the following `npm` modules:
1414

1515
- [markdownlint](https://github.com/DavidAnson/markdownlint): add standardization using [rules](https://github.com/DavidAnson/markdownlint#rules--aliases)
16-
- [markdown-link-check](https://github.com/tcort/markdown-link-check): check the links in the documentation and report broken
17-
ones
16+
- [lychee](https://github.com/lycheeverse/lychee): check the links in the documentation and report broken ones
1817
- [write-good](https://github.com/btford/write-good): linter for English prose
1918

2019
We have been using this pipeline for more than one year in different engagements and always received great feedback from the

docs/UI-UX/recommended-technologies.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ The purpose of this page is to review the commonly selected technology options w
44

55
> Keep in mind that like all software, there is no "right way" to build a user interface application. Leverage and trust your team's or your customer's experience and expertise for the best development experience.
66
7-
Additionally, while some of these technologies are presented as alternate options, many can be combined together. For example, you can use React in a basic HTML/CSS/JS workflow by inline-importing React along with Babel. See the [Add React to a Website](https://reactjs.org/docs/add-react-to-a-website.html) for more details. Similarly, any [Fast](https://www.fast.design/) web component can be [integrated into any existing React application](https://www.fast.design/docs/integrations/react). And of course, every JavaScript technology can also be used with TypeScript!
7+
Additionally, while some of these technologies are presented as alternate options, many can be combined together. For example, you can use React in a basic HTML/CSS/JS workflow by inline-importing React along with Babel. See the [Add React to a Website](https://reactjs.org/docs/add-react-to-a-website.html) for more details. Similarly, any [Fast](https://www.fast.design/) web component can be [integrated into any existing React application](https://fast.design/docs/integrations#react). And of course, every JavaScript technology can also be used with TypeScript!
88

99
## TypeScript
1010

docs/automated-testing/integration-testing/README.md

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -67,9 +67,7 @@ Integration testing demonstrates how one module of a system, or external system,
6767

6868
## Resources
6969

70-
<!-- markdown-link-check-disable -->
7170
- [Integration testing approaches](https://www.softwaretestinghelp.com/what-is-integration-testing/)
72-
<!-- markdown-link-check-enable -->
7371
- [Integration testing pros and cons](https://www.geeksforgeeks.org/software-engineering-integration-testing/)
7472
- [Integration tests mocks and stubs](https://circleci.com/blog/how-to-test-software-part-i-mocking-stubbing-and-contract-testing/)
7573
- [Software Testing: Principles and Practices](https://www.goodreads.com/book/show/21278464-software-testing)

0 commit comments

Comments
 (0)