Skip to content

Commit

Permalink
ci(lint): add lint workflows
Browse files Browse the repository at this point in the history
  • Loading branch information
fu050409 committed Jul 19, 2024
1 parent 2493536 commit 6962b7f
Show file tree
Hide file tree
Showing 4 changed files with 88 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .changeset/small-zebras-speak.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
---
---
22 changes: 22 additions & 0 deletions .github/workflows/cspell.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
name: CSpell

on:
push:
branches: ["main"]
pull_request:
branches: ["main"]

jobs:
lint-cspell:
name: Lint CSpell
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
submodules: recursive
- uses: streetsidesoftware/cspell-action@v6
with:
files: "**"
config: cspell.json
strict: true
verbose: true
38 changes: 38 additions & 0 deletions .github/workflows/lint-pr-title.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Lint Pr Title

on:
pull_request_target:
types:
- opened
- edited
- synchronize
- reopened

permissions:
pull-requests: read

jobs:
lint-pr-title:
name: Validating PR title
runs-on: ubuntu-latest
steps:
- uses: amannn/action-semantic-pull-request@v5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
with:
types: |
fix
feat
docs
style
refactor
perf
test
build
ci
chore
revert
release
requireScope: false
ignoreLabels: |
bot
26 changes: 26 additions & 0 deletions cspell.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
{
"$schema": "https://raw.githubusercontent.com/streetsidesoftware/cspell/main/cspell.schema.json",
"words": [
"aarch",
"androideabi",
"cdylib",
"gnueabihf",
"msvc",
"napi",
"ntscl",
"oxlint",
"prebuild",
"taplo",
"tinybench"
],
"ignoreWords": [
"armv"
],
"ignorePaths": [
"**/node_modules/**",
"**/target/**",
"./npm/*",
"index.js",
"README.md"
]
}

0 comments on commit 6962b7f

Please sign in to comment.