-
Notifications
You must be signed in to change notification settings - Fork 21
41 lines (39 loc) · 1.04 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
---
name: CD
on:
workflow_call: # yamllint disable-line rule:truthy
inputs:
version:
description: 'The version of the package'
required: true
type: string
jobs:
publish:
runs-on: ubuntu-latest
permissions:
id-token: write
contents: write
environment:
name: pypi
url: https://pypi.org/p/data-factory-testing-framework
steps:
- name: Check out repository
uses: actions/checkout@v4
- name: Download sdist
uses: actions/download-artifact@v4
with:
name: sdist
path: dist
- name: Download whl
uses: actions/download-artifact@v4
with:
name: whl
path: dist
- name: Create release
run: gh release create "v${{ inputs.version }}" --prerelease --target ${{ github.ref }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Publish package distributions to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
packages-dir: ./dist