Skip to content

Commit fec70b9

Browse files
Switch markdown linting from mdl to yarn markdownlint-cli2.
Drop the Ruby mdl config and README, and run the same yarn lint command locally and in CI. Co-authored-by: Cursor <cursoragent@cursor.com>
1 parent bfc36ac commit fec70b9

8 files changed

Lines changed: 234 additions & 113 deletions

File tree

‎.github/workflows/build.yml‎

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,6 @@ jobs:
1414
with:
1515
check_hidden: true
1616
path: docs
17-
- name: Run Markdown Lint
18-
uses: DavidAnson/markdownlint-cli2-action@21c1be1b93ad9ed58fa840aacc3f279cde2a72ff # v24.2.0
19-
with:
20-
globs: |
21-
docs/**/*.md
2217
- uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e # v7.0.0
2318
with:
2419
go-version: stable
@@ -28,5 +23,7 @@ jobs:
2823
cache: yarn
2924
- name: Install Dependencies
3025
run: yarn install --frozen-lockfile
26+
- name: Lint Markdown
27+
run: yarn lint
3128
- name: Build website
3229
run: yarn build

‎.markdownlint-cli2.jsonc‎

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,21 @@
11
{
2+
"config": {
3+
"MD001": false,
4+
"MD002": false,
5+
"MD007": { "indent": 2 },
6+
"MD013": { "line_length": 110, "tables": false, "code_blocks": true },
7+
"MD025": false,
8+
"MD026": false,
9+
"MD030": false,
10+
"MD031": false,
11+
"MD033": false,
12+
"MD034": false,
13+
"MD037": false,
14+
"MD041": false,
15+
"MD046": false,
16+
"MD049": false,
17+
"MD050": false
18+
},
219
"ignores": [
320
"docs/install/generated/**",
421
"node_modules/**",

‎.markdownlint.json‎

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

‎.mdlrc‎

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

‎.style‎

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

‎README.md‎

Lines changed: 6 additions & 62 deletions
Original file line numberDiff line numberDiff line change
@@ -1,69 +1,13 @@
11
# unpackerr.zip
22

3-
[This repository](https://github.com/Unpackerr/unpackerr.github.io)
4-
contains the source and files that create [https://unpackerr.zip](https://unpackerr.zip).
5-
6-
## Website
7-
8-
This website is built using [Docusaurus 3](https://docusaurus.io/), a modern static website generator.
9-
10-
## Installation
11-
12-
Clone the repo, then cd into the new folder and run this first.
3+
Source for [https://unpackerr.zip](https://unpackerr.zip). Built with [Docusaurus 3](https://docusaurus.io/).
134

145
```console
156
yarn install
7+
yarn start # local dev server
8+
yarn build # production build
9+
yarn lint # markdownlint-cli2 (same as CI)
10+
codespell docs # brew install codespell
1611
```
1712

18-
## Local Development
19-
20-
**Use this when developing locally!**
21-
22-
This command starts a local development server and open up a browser window.
23-
Most changes are reflected live without having to restart the server.
24-
25-
```console
26-
yarn start
27-
```
28-
29-
## Build
30-
31-
This command generates static content into the `build` directory and can be served using apache or nginx, etc.
32-
33-
```console
34-
yarn build
35-
```
36-
37-
## Deployment
38-
39-
Github Actions automatically builds the `main` branch and pushes it to the `gh-pages` branch.
40-
41-
## Contributing
42-
43-
1. Fork the repo.
44-
1. Make your changes; test them with `yarn`.
45-
1. Test `docs/` with `mdl docs` and `codespell docs`.
46-
1. Make a pull request.
47-
1. Bug me on [Discord](https://golift.io/discord) if I don't respond in a timely manner.
48-
49-
## MDL Linter
50-
51-
To run the linter locally, I had to do this on my Mac, but `bundler` may work too.
52-
GH actions runs a newer version than 0.11.0, but this worked for me for _something_.
53-
54-
```shell
55-
brew install rbenv ruby-build
56-
rbenv install 3.2.2
57-
eval "$(rbenv init -)"
58-
rbenv shell 3.2.2
59-
gem install --no-document mdl
60-
mdl -g docs
61-
```
62-
63-
Seriously, run mdl before committing.
64-
65-
## Codespell Linter
66-
67-
```shell
68-
brew install codespell
69-
```
13+
Push to `main` deploys to GitHub Pages.

‎package.json‎

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,8 @@
99
"swizzle": "docusaurus swizzle",
1010
"deploy": "docusaurus deploy",
1111
"serve": "docusaurus serve",
12-
"clear": "docusaurus clear"
12+
"clear": "docusaurus clear",
13+
"lint": "markdownlint-cli2 'docs/**/*.md'"
1314
},
1415
"dependencies": {
1516
"@docusaurus/core": "3.10.2",
@@ -23,7 +24,8 @@
2324
},
2425
"devDependencies": {
2526
"@docusaurus/module-type-aliases": "3.10.2",
26-
"@docusaurus/types": "3.10.2"
27+
"@docusaurus/types": "3.10.2",
28+
"markdownlint-cli2": "^0.23.2"
2729
},
2830
"browserslist": {
2931
"production": [

0 commit comments

Comments
 (0)