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

Add a parameter to only report on failing links / or add a summary #121

Open
rajbos opened this issue Oct 17, 2021 · 5 comments
Open

Add a parameter to only report on failing links / or add a summary #121

rajbos opened this issue Oct 17, 2021 · 5 comments

Comments

@rajbos
Copy link
Contributor

rajbos commented Oct 17, 2021

I'm checking a lot of links on a run, and finding the failed items in the logs becomes cumbersome (I can search for [x] in the text).

I would like to either have a setting that only shows information about the failed links (and thus hides all the stuff that worked).

-- or --

Add a summary of failed links at the end of the log (maybe a table with file / link / statuscode). That would finding the issues a lot easier.

@gaurav-nelson
Copy link
Owner

@rajbos You can use the use-quiet-mode variable PS https://github.com/gaurav-nelson/github-action-markdown-link-check#custom-variables

@rajbos
Copy link
Contributor Author

rajbos commented Mar 16, 2022

I have that configured, but still super verbose. See my workflow run here: https://github.com/rajbos/rajbos.github.io/runs/5576935018?check_suite_focus=true

@ewels
Copy link

ewels commented Apr 6, 2022

Came here looking for the same thing - the logs are so long it's difficult to find the broken links in all of the output..

Personally, I don't really care how many links have been checked, and don't want to hear about files that had all valid links. Also every dead link is printed twice as a summary and again with the status.

Taking the above actions run as an example, it would be great if we could have something like this:

FILE: ./_posts/2021-05-25-Moving-pester-to-version-5.md
[✖] https://www.globaldevopsbootcamp.com/ → Status: 0

FILE: ./_posts/2021-05-18-Techorama-Using-GitHub-Actions-Securely.md
[✖] /slides/20210518%20GitHub%20Actions%20security%20Techorama.pdf → Status: 400

FILE: ./_posts/2018-08-12-self-signed-certificate-on-sonarqube-server.md
[✖] https://github.com/Azure/azure-quickstart-templates/tree/master/sonarqube-azuresql → Status: 404
[✖] https://docs.sonarqube.org/display/SCAN/Analyzing+with+SonarQube+Extension+for+VSTS-TFS → Status: 404

instead of what is currently printed:

FILE: ./_posts/2021-05-25-Moving-pester-to-version-5.md
[✖] https://www.globaldevopsbootcamp.com/

5 links checked.

ERROR: 1 dead links found!
[✖] https://www.globaldevopsbootcamp.com/ → Status: 0

FILE: ./_posts/2018-08-23-Retrieve-AppSettings-for-an-App-Service-with-the-Fluent-SDK.md

5 links checked.

FILE: ./_posts/2020-02-12-Azure-SQL-Database-Firewall.md

9 links checked.

FILE: ./_posts/2022-01-17-Automating-my-presence.md

10 links checked.

FILE: ./_posts/2020-12-31-DevOps-Maturity-Levels.md

5 links checked.

FILE: ./_posts/2021-02-16-SonarQube-change-branch-community-version.md

1 links checked.

FILE: ./_posts/2018-09-10-GitHub-Azure-DevOps-Pipeline.md

21 links checked.

FILE: ./_posts/2021-05-18-Techorama-Using-GitHub-Actions-Securely.md
[✖] /slides/20210518%20GitHub%20Actions%20security%20Techorama.pdf

6 links checked.

ERROR: 1 dead links found!
[✖] /slides/20210518%20GitHub%20Actions%20security%20Techorama.pdf → Status: 400

FILE: ./_posts/2021-05-16-Dont-use-self-signed-certificates-on-GitHub-Enterprise.md

3 links checked.

FILE: ./_posts/2020-08-07-ADAL-error-Azure-DevOps.md

6 links checked.

FILE: ./_posts/2018-08-12-self-signed-certificate-on-sonarqube-server.md
[✖] https://github.com/Azure/azure-quickstart-templates/tree/master/sonarqube-azuresql
[✖] https://docs.sonarqube.org/display/SCAN/Analyzing+with+SonarQube+Extension+for+VSTS-TFS

14 links checked.

ERROR: 2 dead links found!
[✖] https://github.com/Azure/azure-quickstart-templates/tree/master/sonarqube-azuresql → Status: 404
[✖] https://docs.sonarqube.org/display/SCAN/Analyzing+with+SonarQube+Extension+for+VSTS-TFS → Status: 404

@gaurav-nelson
Copy link
Owner

@ewels @rajbos Thank you for adding to the conversation. I'm opening this issues again, hopefully tackle it sometime.

@fharper
Copy link

fharper commented Jul 15, 2023

I also find it difficult as I'm checking hundreds of Markdown files.

Maybe this should be an option englobing verbose, and use-quiet-mode as a verbose with four options:

  • normal (default option): equivalent to not setting verbose to yes or use-quiet-mode to yes
  • verbose: equivalent of setting verbose to yes
  • quiet: equivalent of setting use-quiet-mode to yes
  • error: equivalent of a super quiet mode, like the first example of @ewels

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

No branches or pull requests

4 participants