-
Notifications
You must be signed in to change notification settings - Fork 0
79 lines (77 loc) · 2.38 KB
/
release.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
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
on:
workflow_call:
inputs:
releases:
description: |
A JSON list of releases to run
required: true
type: string
force:
description: |
Force the release to run even if no events are triggered
required: false
type: string
default: "false"
forge_version:
description: |
The version of the forge CLI to install (use 'local' for testing)
required: true
type: string
local:
description: Forces local mode
required: false
type: string
default: "false"
verbosity:
description: The verbosity level to use
required: false
type: string
default: "info"
secrets:
earthly_token:
description: Optional Earthly token used to login to Earthly cloud during local builds of Forge CLI
required: false
env:
OUTPUT: ${{ github.workspace }}/output
jobs:
run:
name: ${{ matrix.release.project }} (${{ matrix.release.name}})
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
release: ${{ fromJson(inputs.releases) }}
steps:
- uses: actions/checkout@v4
- name: Install Forge
uses: input-output-hk/catalyst-forge/actions/install@master
if: ${{ inputs.forge_version != 'local' }}
with:
version: ${{ inputs.forge_version }}
- name: Install Local Forge
uses: input-output-hk/catalyst-forge/actions/install-local@master
if: ${{ inputs.forge_version == 'local' }}
with:
earthly_token: ${{ secrets.earthly_token }}
- name: Check forge version
id: local
run: |
forge version
if [[ "${{ inputs.forge_version }}" == "local" ]]; then
echo "skip=true" >> $GITHUB_OUTPUT
else
echo "skip=false" >> $GITHUB_OUTPUT
fi
- name: Setup CI
uses: input-output-hk/catalyst-forge/actions/setup@master
with:
skip_earthly: ${{ steps.local.outputs.skip }}
- name: Release
uses: input-output-hk/catalyst-forge/actions/run@master
with:
command: release
args: ${{ matrix.release.project }} ${{ matrix.release.name }}
local: ${{ inputs.local }}
verbosity: ${{ inputs.verbosity }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}