Skip to content

Commit

Permalink
➕ add pyright
Browse files Browse the repository at this point in the history
  • Loading branch information
StarHeartHunt committed Aug 2, 2023
1 parent dd8eb00 commit 793126a
Show file tree
Hide file tree
Showing 5 changed files with 158 additions and 128 deletions.
24 changes: 24 additions & 0 deletions .github/workflows/pyright.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Pyright Lint

on:
push:
branches:
- master
pull_request:
paths:
- "nonebot/**"

jobs:
pyright:
name: Pyright Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3

- name: Setup Python environment
uses: ./.github/actions/setup-python

- run: echo "$(poetry env info --path)/bin" >> $GITHUB_PATH

- name: Run Pyright
uses: jakebailey/pyright-action@v1
7 changes: 4 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,14 +7,15 @@
"scripts": {
"archive": "yarn workspace website docusaurus docs:version",
"build": "yarn workspace website build",
"build:plugin": "cross-env BASE_URL='/docs/' yarn workspace website build",
"start": "yarn workspace website start",
"serve": "yarn workspace website serve",
"clear": "yarn workspace website clear",
"prettier": "prettier --config ./.prettierrc --write \"./website/\""
"prettier": "prettier --config ./.prettierrc --write \"./website/\"",
"pyright": "pyright"
},
"devDependencies": {
"cross-env": "^7.0.3",
"prettier": "^2.5.0"
"prettier": "^2.5.0",
"pyright": "^1.1.317"
}
}
Loading

0 comments on commit 793126a

Please sign in to comment.