-
Notifications
You must be signed in to change notification settings - Fork 9
72 lines (69 loc) · 2.11 KB
/
build-and-release.yaml
File metadata and controls
72 lines (69 loc) · 2.11 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
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
name: Build and Release Snap
on:
push:
branches:
- master
workflow_dispatch:
jobs:
build-and-release-stable:
runs-on: ${{ matrix.architecture.runner }}
strategy:
matrix:
architecture:
- arch: amd64
runner: ubuntu-24.04
- arch: armhf
runner: ubuntu-24.04-arm
- arch: arm64
runner: ubuntu-24.04-arm
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Build
id: build
uses: diddlesnaps/snapcraft-multiarch-action@v1
with:
architecture: ${{ matrix.architecture.arch }}
use-podman: 'true'
- name: Massage the snap name
id: snap-name
run: echo "snap=$(echo ${{ steps.build.outputs.snap }} | sed -Ee 's@^'"${GITHUB_WORKSPACE}"'/?@@')" >> "$GITHUB_OUTPUT"
- name: Publish release to Beta
id: release
uses: diddlesnaps/snapcraft-multiarch-action@v1
with:
use-podman: 'true'
store-auth: ${{ secrets.STORE_LOGIN }}
snapcraft-args: upload --release=beta ${{ steps.snap-name.outputs.snap }}
build-and-release-playtest:
runs-on: ${{ matrix.architecture.runner }}
strategy:
matrix:
architecture:
- arch: amd64
runner: ubuntu-24.04
- arch: armhf
runner: ubuntu-24.04-arm
- arch: arm64
runner: ubuntu-24.04-arm
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Set playtest=true
run: echo 'PLAYTEST="true"' > build-type
- name: Build
id: build
uses: diddlesnaps/snapcraft-multiarch-action@v1
with:
architecture: ${{ matrix.architecture.arch }}
use-podman: 'true'
- name: Massage the snap name
id: snap-name
run: echo "snap=$(echo ${{ steps.build.outputs.snap }} | sed -Ee 's@^'"${GITHUB_WORKSPACE}"'/?@@')" >> "$GITHUB_OUTPUT"
- name: Publish release to Edge
id: release
uses: diddlesnaps/snapcraft-multiarch-action@v1
with:
use-podman: 'true'
store-auth: ${{ secrets.STORE_LOGIN }}
snapcraft-args: upload --release=edge ${{ steps.snap-name.outputs.snap }}