Add fmt in ci #5
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
concurrency: | |
group: ci-${{ github.event.pull_request.number || github.ref }} | |
cancel-in-progress: true | |
jobs: | |
lint: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Hatch | |
uses: pypa/hatch@install | |
- name: Run Lint | |
run: | | |
hatch fmt --check | |
build: | |
runs-on: ubuntu-latest | |
needs: lint | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Hatch | |
uses: pypa/hatch@install | |
- name: Run Build | |
run: | | |
hatch env create | |
hatch build | |
test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Install Hatch | |
uses: pypa/hatch@install | |
- name: Run Test | |
env: | |
FYMAIL_GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
run: | | |
hatch env create test | |
hatch test |