-
Notifications
You must be signed in to change notification settings - Fork 25
47 lines (45 loc) · 1.08 KB
/
job_publish.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: job_publish
on:
workflow_call:
inputs:
version:
required: true
type: string
file1:
required: true
type: string
name1:
required: true
type: string
name2:
type: string
default: ""
file2:
type: string
default: ""
jobs:
release:
name: Publish
runs-on: ubuntu-latest
strategy:
matrix:
include:
- name: ${{ inputs.name1 }}
file: ${{ inputs.file1 }}
- name: ${{ inputs.name2 }}
file: ${{ inputs.file2 }}
steps:
- name: Download ${{ matrix.name }} from artifacts
uses: actions/download-artifact@v4
if: ${{ matrix.name != '' }}
with:
name: ${{ matrix.name }}
- name: Upload ${{ matrix.name }} to release
uses: svenstaro/upload-release-action@v2
if: ${{ matrix.name != '' }}
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: ${{ matrix.file }}
asset_name: ${{ matrix.name }}
tag: ${{ inputs.version }}
overwrite: true