-
-
Notifications
You must be signed in to change notification settings - Fork 638
Add automated markdown link checking GitHub Action #1800
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
Merged
Merged
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
a2970b1
Add GitHub Action for automated markdown link checking
ihabadham 1fdda76
Update Gemfile.lock to version 16.0.1.rc.2
ihabadham c6fad48
Fix broken spec/dummy file links in documentation
ihabadham 7a6fb6d
Fix broken configuration, repository structure, and typo links
ihabadham dba84c9
Mark Webpacker v3-v4 upgrade guide as outdated
ihabadham bff4ab7
Replace deprecated markdown-link-check action with maintained fork
ihabadham c6293cf
Include config file in workflow paths trigger
ihabadham 30c931b
Pin markdown-link-check action to specific commit SHA for security
ihabadham ea30632
Fix other old docs links and configure markdown link checker to ignor…
ihabadham b286f82
Update reactrails.com links to use HTTPS
ihabadham c671785
Fix remaining broken documentation links
ihabadham a6102e0
make notes more clear for upgrade-webpacker-v3-to-v4.md
ihabadham 1545d37
remove dead links
ihabadham File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,47 @@ | ||
| { | ||
| "ignorePatterns": [ | ||
| { | ||
| "pattern": "^http://localhost" | ||
| }, | ||
| { | ||
| "pattern": "^https://localhost" | ||
| }, | ||
| { | ||
| "pattern": "^mailto:" | ||
| }, | ||
| { | ||
| "pattern": "^https://www\\.npmjs\\.(org|com)" | ||
| }, | ||
| { | ||
| "pattern": "^https://your-shared-addr\\.c9users\\.io" | ||
| }, | ||
| { | ||
| "pattern": "^https://hichee\\.com" | ||
| }, | ||
| { | ||
| "pattern": "^https://github\\.com/shakacode/react-webpack-rails-tutorial/blob/master/config/webpacker\\.yml$" | ||
| }, | ||
| { | ||
| "pattern": "^https://github\\.com/shakacode/react-webpack-rails-tutorial/blob/master/client/webpack\\.client\\.base\\.config\\.js" | ||
| } | ||
| ], | ||
| "replacementPatterns": [ | ||
| { | ||
| "pattern": "^/", | ||
| "replacement": "https://github.com/shakacode/react_on_rails/blob/master/" | ||
| } | ||
| ], | ||
| "httpHeaders": [ | ||
| { | ||
| "urls": ["https://docs.github.com", "https://github.com"], | ||
| "headers": { | ||
| "Accept": "text/html" | ||
| } | ||
| } | ||
| ], | ||
| "timeout": "20s", | ||
| "retryOn429": true, | ||
| "retryCount": 3, | ||
| "fallbackRetryDelay": "30s", | ||
| "aliveStatusCodes": [200, 206] | ||
| } | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,36 @@ | ||
| name: Check Markdown Links | ||
|
|
||
| on: | ||
| push: | ||
| branches: [master] | ||
| paths: | ||
| - '**.md' | ||
| - '.github/workflows/check-markdown-links.yml' | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. The config file |
||
| - '.github/markdown-link-check-config.json' | ||
| pull_request: | ||
| paths: | ||
| - '**.md' | ||
| - '.github/workflows/check-markdown-links.yml' | ||
| - '.github/markdown-link-check-config.json' | ||
| schedule: | ||
| # Run weekly on Monday at 8am UTC | ||
| - cron: '0 8 * * 1' | ||
| workflow_dispatch: | ||
|
|
||
| jobs: | ||
| markdown-link-check: | ||
| runs-on: ubuntu-latest | ||
| steps: | ||
| - uses: actions/checkout@v4 | ||
|
|
||
| - name: Check markdown links | ||
| uses: tcort/github-action-markdown-link-check@a800ad5f1c35bf61987946fd31c15726a1c9f2ba # v1.1.0 | ||
| with: | ||
| use-quiet-mode: 'yes' | ||
| use-verbose-mode: 'no' | ||
| config-file: '.github/markdown-link-check-config.json' | ||
| folder-path: 'docs/' | ||
| file-extension: '.md' | ||
| max-depth: -1 | ||
| check-modified-files-only: 'no' | ||
| base-branch: 'master' | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,10 +1,12 @@ | ||
| # Upgrading rails/webpacker v3.5 to v4 | ||
| # Upgrading rails/webpacker v3.5 to v4 (Outdated) | ||
|
|
||
| _Note: This guide is outdated. The configuration files it references were removed when React on Rails moved to Shakapacker. For migrating from Webpacker to Shakapacker, see the Shakapacker guide to upgrading to [version 6](https://github.com/shakacode/shakapacker/blob/master/docs/v6_upgrade.md) and [version 7](https://github.com/shakacode/shakapacker/blob/master/docs/v7_upgrade.md)._ | ||
|
|
||
| The following steps can be followed to update a Webpacker v3.5 app to v4. | ||
|
|
||
| 1. Update the gem `webpacker` and the package `@rails/webpacker` | ||
| 1. Merge changes from the new default [.babelrc](https://github.com/shakacode/react_on_rails/tree/master/lib/install/config/.babelrc) to your `/.babelrc`. If you are using React, you need to add `"@babel/preset-react"`, to the list of `presets`. | ||
| 1. Copy the file [.browserslistrc](https://github.com/shakacode/react_on_rails/tree/master/lib/install/config/.browserslistrc) to `/`. | ||
| 1. Merge any differences between [config/webpacker.yml](https://github.com/shakacode/react_on_rails/tree/master/lib/install/config/webpacker.yml) and your `/config/webpacker.yml`. | ||
| 1. Merge changes from the new default `.babelrc` to your `/.babelrc`. If you are using React, you need to add `"@babel/preset-react"`, to the list of `presets`. | ||
| 1. Copy the file `.browserslistrc` to `/`. | ||
| 1. Merge any differences between `config/webpacker.yml` and your `/config/webpacker.yml`. | ||
|
|
||
| Here is an [example commit of these changes](https://github.com/shakacode/react_on_rails-tutorial-v11/pull/1/files). |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why do you make the tool ignore URLs that point to the "react-webpack-rails-tutorial" repo?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This change is only for the webpacker.yml file, because it's not in the current master branch of
react-webpack-rails-tutorial, so it will cause a 404 error when the checker runs. We should keep it for people upgrading, so I'm ignoring it to avoid triggering the checker workflow. Am I missing something?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You can update links to refer for files from the commit at which these files are created