Skip to content

Commit 1ea9f16

Browse files
committed
Add a config file for remark
1 parent a7f78c5 commit 1ea9f16

File tree

2 files changed

+25
-19
lines changed

2 files changed

+25
-19
lines changed

.github/workflows/check.yml

Lines changed: 5 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -65,32 +65,18 @@ jobs:
6565
exit $total_exit_code
6666
- name: Remark
6767
run: |
68-
yarn add remark-cli \
68+
npm install yarn
69+
./node_modules/.bin/yarn --version
70+
./node_modules/.bin/yarn --help
71+
./node_modules/.bin/yarn add remark-cli \
6972
remark-lint-mdash-style \
7073
https://github.com/typeable/remark-validate-links#anchors \
7174
remark-preset-lint-recommended \
7275
remark-lint-no-dead-urls
7376
7477
total_exit_code=0
7578
while IFS= read -r file; do
76-
yarn run remark -f \
77-
-u validate-links \
78-
-u remark-lint-mdash-style \
79-
-u remark-lint-final-newline \
80-
-u remark-lint-list-item-bullet-indent \
81-
-u remark-lint-no-blockquote-without-marker \
82-
-u remark-lint-ordered-list-marker-style \
83-
-u remark-lint-no-literal-urls \
84-
-u remark-lint-hard-break-spaces \
85-
-u remark-lint-no-duplicate-definitions \
86-
-u remark-lint-no-heading-content-indent \
87-
-u remark-lint-no-inline-padding \
88-
-u remark-lint-no-shortcut-reference-image \
89-
-u remark-lint-no-shortcut-reference-link \
90-
-u remark-lint-no-undefined-references \
91-
-u remark-lint-no-unused-definitions \
92-
-u remark-lint-no-dead-urls \
93-
$file || total_exit_code=$?
79+
yarn run remark -f $file || total_exit_code=$?
9480
done < <(find . -name "*.md" -not -path "*/node_modules/*" -not -path "./.github/*")
9581
exit $total_exit_code
9682
- name: Cargo clippy

.remarkrc

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
{
2+
"plugins": [
3+
"validate-links",
4+
"remark-lint-mdash-style",
5+
"remark-lint-final-newline",
6+
"remark-lint-list-item-bullet-indent",
7+
"remark-lint-no-blockquote-without-marker",
8+
"remark-lint-ordered-list-marker-style",
9+
"remark-lint-no-literal-urls",
10+
"remark-lint-hard-break-spaces",
11+
"remark-lint-no-duplicate-definitions",
12+
"remark-lint-no-heading-content-indent",
13+
"remark-lint-no-inline-padding",
14+
"remark-lint-no-shortcut-reference-image",
15+
"remark-lint-no-shortcut-reference-link",
16+
"remark-lint-no-undefined-references",
17+
"remark-lint-no-unused-definitions",
18+
"remark-lint-no-dead-urls"
19+
]
20+
}

0 commit comments

Comments
 (0)