forked from aws-deadline/.github
-
Notifications
You must be signed in to change notification settings - Fork 0
53 lines (47 loc) · 1.55 KB
/
Copy pathreusable_prerelease.yml
File metadata and controls
53 lines (47 loc) · 1.55 KB
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
50
51
52
53
name: "Prerelease"
on:
workflow_call:
inputs:
tag:
required: true
type: string
jobs:
PreRelease:
runs-on: ubuntu-latest
environment: release
permissions:
id-token: write
contents: write
steps:
- name: Checkout
uses: actions/checkout@v4
with:
ref: refs/tags/${{inputs.tag}}
fetch-depth: 0
token: ${{ secrets.CI_TOKEN }}
- name: Build
run: |
pip install --upgrade hatch
hatch -v build
# A precommit hook into the GitHub Action workflow.
# If the workflow file .github/actions/prepush_release_hook exists in the repository
# that is using this workflow, then this will run the workflow defined in that file.
# That workflow must be defined to accept all of the inputs in the 'with' clause below.
# Uses:
# If a package publish needs to publish additional files to the GitHub release, then
# it should use this hook to:
# 1. create a dist_extras/ directory
# 2. add all additional files to publish into that directory that aren't publishable to PyPI
- name: PrePushReleaseHook
uses: ./.github/actions/prepush_release_hook
if: ${{ hashFiles('./.github/actions/prepush_release_hook/action.yml') != '' }}
with:
semver: ${{ inputs.tag }}
tag: ${{ inputs.tag }}
- name: UploadArtifacts
uses: actions/upload-artifact@v4
with:
name: build-artifact
path: |
dist
dist_extras