Skip to content

Commit

Permalink
Set up linter checks
Browse files Browse the repository at this point in the history
  • Loading branch information
alephtwo committed Mar 14, 2024
1 parent 874a8ff commit 3e5abf5
Show file tree
Hide file tree
Showing 4 changed files with 82 additions and 0 deletions.
56 changes: 56 additions & 0 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,56 @@
---
name: "Lint"
on:
push:
workflow_call:
jobs:
eslint:
name: "Run eslint"
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v4"
- uses: "actions/setup-node@v4"
with:
node-version: "lts/iron"
cache: "npm"
- name: "Install Dependencies"
run: "npm ci"
- name: "Run eslint"
run: "npm run lint:ts"
prettier:
name: "Run Prettier"
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v4"
- uses: "actions/setup-node@v4"
with:
node-version: "lts/iron"
cache: "npm"
- name: "Install Dependencies"
run: "npm ci"
- name: "Run prettier"
run: "npm run prettier"
markdownlint:
name: "Run Markdownlint"
runs-on: "ubuntu-latest"
steps:
- uses: "actions/checkout@v4"
- uses: "actions/setup-node@v4"
with:
node-version: "lts/iron"
cache: "npm"
- name: "Install Dependencies"
run: "npm ci"
- name: "Run markdownlint"
run: "npm run mdl"
yaml:
name: "Lint YAML"
runs-on: "ubuntu-latest"
container:
image: "alpine:latest"
steps:
- uses: "actions/checkout@v4"
- name: "Install yamllint"
run: "apk add yamllint"
- name: "Run yamllint"
run: "yamllint -s ."
6 changes: 6 additions & 0 deletions .markdownlint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
{
"line-length": {
"code_blocks": false,
"tables": false
}
}
4 changes: 4 additions & 0 deletions .markdownlintignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
/node_modules
/target
/sounds
/LICENSE.md
16 changes: 16 additions & 0 deletions .yamllint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
---
extends: "default"
ignore:
- "/node_modules"
- "/target"
- "/sounds"
rules:
truthy:
check-keys: false
line-length:
max: 120
allow-non-breakable-words: true
allow-non-breakable-inline-mappings: true
quoted-strings:
quote-type: "double"
required: true

0 comments on commit 3e5abf5

Please sign in to comment.