Skip to content

Commit

Permalink
ci(lint): add cspell and pr-title lint ci (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
fu050409 authored Jul 12, 2024
1 parent c187ac1 commit e791a31
Show file tree
Hide file tree
Showing 5 changed files with 89 additions and 7 deletions.
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
29 changes: 29 additions & 0 deletions cspell.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"version": "0.2",
"language": "en",
"words": [
"Avenir",
"cdylib",
"grassator",
"icns",
"noctisynth",
"serde",
"staticlib",
"tauri"
],
"ignorePaths": [
// Tauri files
"**/Cargo.lock",
"**/target/**",
"./src-tauri/gen/**",

// Github actions
".github/**",

// Node files
"src/assets/**",
"public/**",
"dist/**",
"pnpm-lock.yaml"
]
}
6 changes: 0 additions & 6 deletions public/tauri.svg

This file was deleted.

1 change: 0 additions & 1 deletion public/vite.svg

This file was deleted.

0 comments on commit e791a31

Please sign in to comment.