-
Notifications
You must be signed in to change notification settings - Fork 38
47 lines (39 loc) · 1.22 KB
/
build.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
name: build
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
release:
name: Release
runs-on: ubuntu-latest
#needs: [test]
steps:
- name: Checkout
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v2
with:
node-version: '18'
- name: Setup
run: npm install -g semantic-release @semantic-release/github @semantic-release/changelog @semantic-release/commit-analyzer @semantic-release/git @semantic-release/release-notes-generator semantic-release-pypi
- name: Set up python
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Install setuptools
run: python -m pip install --upgrade setuptools wheel twine
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install black ruff pre-commit
- name: Run linter
run: git diff --name-only HEAD~10 HEAD | xargs pre-commit run --files
- name: Release
env:
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}
PYPI_TOKEN: ${{ secrets.PYPI_TOKEN }}
run: npx semantic-release