-
Notifications
You must be signed in to change notification settings - Fork 1
47 lines (40 loc) · 1.17 KB
/
publish-release.yml
File metadata and controls
47 lines (40 loc) · 1.17 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
# based on https://github.com/elixir-mint/castore/blob/22d0a4efd41b97f55aab48e170f2520c338341b9/.github/workflows/publish.yml
# by Eric Meadows-Jönsson (@ericmj)
on:
workflow_call:
inputs:
elixir_version:
required: true
type: string
otp_version:
required: true
type: string
jobs:
publish-release:
name: Publish
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Erlang & Elixir
uses: erlef/setup-beam@v1
with:
elixir-version: ${{ inputs.elixir_version }}
otp-version: ${{ inputs.otp_version }}
# Caching
- name: Dependencies cache
uses: actions/cache/restore@v4
with:
path: deps
key: ${{ runner.os }}-deps-${{ hashFiles('mix.lock') }}
- name: Build cache
uses: actions/cache/restore@v4
with:
path: _build
key: ${{ runner.os }}-build-dev-${{inputs.elixir_version}}-${{inputs.otp_version}}-${{ hashFiles('mix.lock') }}
# Run
- name: Publish release
run: .github/workflows/publish-release.sh
env:
HEX_API_KEY: ${{ secrets.HEX_API_KEY }}