Skip to content

Commit

Permalink
fix: modify the markdown check from local to call markdown check in `…
Browse files Browse the repository at this point in the history
…catalyst-ci` (#176)

* fix: markdownlint-disable name for require-headings

* fix: change markdown check local to remotely call check

* chore: change name

* ci: remove markdown-check in github action

* fix: add check markdown to check target

---------

Co-authored-by: Steven Johnson <stevenj@users.noreply.github.com>
  • Loading branch information
bkioshn and stevenj authored Dec 7, 2023
1 parent ab320a6 commit 9337c73
Show file tree
Hide file tree
Showing 7 changed files with 14 additions and 29 deletions.
14 changes: 0 additions & 14 deletions .github/workflows/markdown-check.yml

This file was deleted.

2 changes: 1 addition & 1 deletion .markdownlint.jsonc
Original file line number Diff line number Diff line change
Expand Up @@ -187,7 +187,7 @@
},
// MD042/no-empty-links - No empty links
"MD042": true,
// MD043/required-headings/required-headers - Required heading structure
// MD043/required-headings/required-headings - Required heading structure
"MD043": {
// List of headings
"headings": [
Expand Down
6 changes: 3 additions & 3 deletions .vscode/tasks.recommended.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,9 +4,9 @@
{
"label": "CI - Recursive Markdown Lint - Check",
"type": "shell",
"command": "earthly -P +markdown-check",
"command": "earthly -P +check-markdown",
"problemMatcher": {
"owner": "markdown-check",
"owner": "check-markdown",
"pattern": {
"regexp": "(\\S+):(\\d+):(\\d+)\\s(.+)",
"file": 1,
Expand All @@ -24,7 +24,7 @@
"type": "shell",
"command": "earthly -P +markdown-check-fix",
"problemMatcher": {
"owner": "markdown-check",
"owner": "markdown-check-fix",
"pattern": {
"regexp": "(\\S+):(\\d+):(\\d+)\\s(.+)",
"file": 1,
Expand Down
15 changes: 7 additions & 8 deletions Earthfile
Original file line number Diff line number Diff line change
Expand Up @@ -5,25 +5,24 @@ FROM debian:stable-slim

# cspell: words livedocs sitedocs

markdown-check:
# Check Markdown in this repo.
LOCALLY

DO github.com/input-output-hk/catalyst-ci/earthly/mdlint:v2.0.9+MDLINT_LOCALLY --src=$(echo ${PWD})
# check-markdown markdown check using catalyst-ci.
check-markdown:
DO github.com/input-output-hk/catalyst-ci/earthly/mdlint:v2.0.10+CHECK

# markdown-check-fix markdown check and fix using catalyst-ci.
markdown-check-fix:
# Check Markdown in this repo.
LOCALLY

DO github.com/input-output-hk/catalyst-ci/earthly/mdlint:v2.0.9+MDLINT_LOCALLY --src=$(echo ${PWD}) --fix=--fix
DO github.com/input-output-hk/catalyst-ci/earthly/mdlint:v2.0.10+MDLINT_LOCALLY --src=$(echo ${PWD}) --fix=--fix

# check-spelling Check spelling in this repo inside a container.
check-spelling:
DO github.com/input-output-hk/catalyst-ci/earthly/cspell:v2.0.10+CHECK

check:
BUILD +check-spelling

BUILD +check-markdown

repo-docs:
# Create artifacts of extra files we embed inside the documentation when its built.
FROM scratch
Expand Down
2 changes: 1 addition & 1 deletion docs/src/appendix/important/coc.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,5 @@ title: Code of Conduct
---

<!-- markdownlint-disable first-line-h1 -->
<!-- markdownlint-disable required-headers -->
<!-- markdownlint-disable required-headings -->
{{ include_file('includes/repo/CODE_OF_CONDUCT.md') }}
2 changes: 1 addition & 1 deletion docs/src/appendix/important/contributing.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ icon: material/pen-plus
---

<!-- markdownlint-disable first-line-h1 -->
<!-- markdownlint-disable required-headers -->
<!-- markdownlint-disable required-headings -->
{{ include_file('includes/repo/CONTRIBUTING.md') }}
2 changes: 1 addition & 1 deletion docs/src/appendix/important/security.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,5 +3,5 @@ icon: material/security
---

<!-- markdownlint-disable first-line-h1 -->
<!-- markdownlint-disable required-headers -->
<!-- markdownlint-disable required-headings -->
{{ include_file('includes/repo/SECURITY.md') }}

0 comments on commit 9337c73

Please sign in to comment.