-
Notifications
You must be signed in to change notification settings - Fork 3
49 lines (41 loc) · 1.23 KB
/
cd.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
48
49
name: 🚀 Release
on:
workflow_dispatch:
inputs:
root_options:
description: "Options: semantic-release <options>, es: --noop"
default: "-v"
required: false
type: string
jobs:
release:
runs-on: ubuntu-latest
concurrency: release
name: Release to PyPI 🐍
permissions:
id-token: write
contents: write
steps:
- name: 📌 Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: 🗂️ Generate Version and Changelog with Semantic Release
id: release
uses: python-semantic-release/[email protected]
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
root_options: ${{ github.event.inputs.root_options }}
- name: 🚧 Setup build environment
uses: actions/setup-python@v4
with:
python-version: "3.x"
cache: "pip"
- name: 🧩 Install build dependencies
run: |
python -m pip install --upgrade pip
pip install build
- name: 📦 Build package distributions
run: python -m build
- name: 📤 Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1