Skip to content

Commit a6dd50b

Browse files
authored
chore: check markdown files (#34)
* add job * add config * add script * add dependencies * fix findings
1 parent f939f2d commit a6dd50b

File tree

7 files changed

+107
-16
lines changed

7 files changed

+107
-16
lines changed

.github/preview1.png

38.5 KB
Loading

.github/workflows/validation.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,16 @@ jobs:
2626
run: npm clean-install
2727
- name: Validate JS Sources
2828
run: npm run validate:js
29+
markdownlint:
30+
runs-on: ubuntu-latest
31+
name: 'MarkdownLint'
32+
steps:
33+
- name: Checkout Code
34+
uses: actions/checkout@v4
35+
- name: Validate Markdown Sources
36+
uses: nosborn/github-action-markdown-cli@v3.3.0
37+
with:
38+
files: .
2939
package-lock-is-up-to-date:
3040
runs-on: ubuntu-latest
3141
steps:

.markdownlint.yml

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
default: true
2+
3+
# ignore
4+
MD013: false # line-length
5+
MD041: false # first-line-heading/first-line-h1

README.md

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -13,10 +13,9 @@ A module for the [MagicMirror](https://github.com/MichMich/MagicMirror) to displ
1313

1414
## Preview
1515

16-
<img width="318" alt="Bildschirmfoto 2022-01-20 um 06 57 01" src="https://user-images.githubusercontent.com/9592452/150281894-a4c87c58-5080-42fb-99c5-d63b10c3c320.png">
16+
![preview](.github/preview1.png)
1717

18-
19-
![preview](.github/preview.png)
18+
![preview](.github/preview2.png)
2019

2120
## Usage
2221

@@ -36,13 +35,13 @@ Add the module configuration to your `config.js` file.
3635

3736
```js
3837
{
39-
module: 'MMM-AirQuality',
40-
position: 'top_center', // you may choose any location
41-
header: 'AQI', //choose a header if you like
42-
config: {
43-
location: 'beijing' // the location to check the index for
38+
module: 'MMM-AirQuality',
39+
position: 'top_center', // you may choose any location
40+
header: 'AQI', //choose a header if you like
41+
config: {
42+
location: 'beijing' // the location to check the index for
4443
token: '' // add your token here
45-
}
44+
}
4645
},
4746
```
4847

@@ -52,7 +51,7 @@ To use the WAQI API you need to [request a token](https://aqicn.org/data-platfor
5251

5352
### Location
5453

55-
Determine the station you want to display. Select a station on the [map](https://aqicn.org/here/) and copy the location part from the URL. For example http://aqicn.org/city/netherland/utrecht/griftpark/ would be `netherland/utrecht/griftpark/`.
54+
Determine the station you want to display. Select a station on the [map](https://aqicn.org/here/) and copy the location part from the URL. For example `http://aqicn.org/city/netherland/utrecht/griftpark/` would be `netherland/utrecht/griftpark/`.
5655

5756
You may also get the data for specific longitude and latitude. Set the `location` to `geo:<lat>;<long>/` and replace `<lat>` and `<long>` with your values.
5857

@@ -71,7 +70,7 @@ You may want to set the following options in the config section as well:
7170

7271
- Due to the AQI rendering script it is not possible to have multiple instances of this module running.
7372
- There is a bug in the skript that prevent some locations from being displayed (e.g. 'Mannheim').
74-
- Not all languages may be supported (see: http://aqicn.org/faq/2015-07-28/air-quality-widget-new-improved-feed/).
73+
- Not all languages may be supported (see: <http://aqicn.org/faq/2015-07-28/air-quality-widget-new-improved-feed/>).
7574

7675
## Contributors ✨
7776

@@ -93,4 +92,4 @@ Thanks goes to these wonderful people ([emoji key](https://allcontributors.org/d
9392

9493
<!-- ALL-CONTRIBUTORS-LIST:END -->
9594

96-
This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!
95+
This project follows the [all-contributors](https://github.com/all-contributors/all-contributors) specification. Contributions of any kind welcome!

package-lock.json

Lines changed: 76 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,13 @@
1919
"author": "Christopher Fenner",
2020
"license": "MIT",
2121
"scripts": {
22-
"validate": "npm run validate:js",
23-
"validate:js": "eslint **/*.js"
22+
"validate": "npm run validate:js && npm run validate:md",
23+
"validate:js": "eslint **/*.js",
24+
"validate:md": "node_modules/.bin/markdownlint *.md"
2425
},
2526
"devDependencies": {
2627
"eslint": "8.56.0",
27-
"eslint-config-standard": "17.1.0"
28+
"eslint-config-standard": "17.1.0",
29+
"markdownlint": "0.32.1"
2830
}
2931
}

0 commit comments

Comments
 (0)