-
Notifications
You must be signed in to change notification settings - Fork 5
51 lines (45 loc) · 1.4 KB
/
manual_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
name: Manual Release
on:
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
release:
needs: [test]
runs-on: ubuntu-20.04
outputs:
version: ${{ steps.release.outputs.release }}
steps:
- uses: actions/checkout@v3
- name: Set release
id: semrel
uses: go-semantic-release/action@v1
with:
github-token: ${{ secrets.GITHUB_TOKEN }}
force-bump-patch-version: true
- name: Output release
id: release
run: echo "::set-output name=release::${{ steps.semrel.outputs.version }}"
test:
uses: ./.github/workflows/test.yml
secrets:
auth-token: ${{ secrets.ALPHA_TEST_AUTH_TOKEN }}
github-token: ${{ secrets.MOMENTO_MACHINE_USER_GITHUB_TOKEN }}
publish_golang:
needs: [test, release]
runs-on: ubuntu-latest
steps:
- name: Setup repo
uses: actions/checkout@v3
- name: Publish package
run: |
set -e
set -x
export MOMENTO_SDK_VERSION="${{needs.release.outputs.version}}"
if [ -z "$MOMENTO_SDK_VERSION"]
then
echo "Unable to determine SDK version! Exiting!"
exit 1
fi
echo "MOMENTO_SDK_VERSION=${MOMENTO_SDK_VERSION}"
GOPROXY=proxy.golang.org go list -m github.com/momentohq/client-sdk-go@v${MOMENTO_SDK_VERSION}
shell: bash