Skip to content

Commit 9571e54

Browse files
committed
Add MacOS euphoria action
[macos-euphoria]
1 parent b13152b commit 9571e54

File tree

1 file changed

+68
-0
lines changed

1 file changed

+68
-0
lines changed
Lines changed: 68 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,68 @@
1+
name: macos-euphoria
2+
3+
on: [push]
4+
5+
jobs:
6+
7+
Build-Euphoria-MacOS:
8+
name: 'Euphoria for MacOS'
9+
runs-on: macos-13
10+
if: |
11+
contains(github.event.head_commit.message, '[all]') ||
12+
contains(github.event.head_commit.message, '[macos]') ||
13+
contains(github.event.head_commit.message, '[macos-euphoria]') ||
14+
contains(github.event.head_commit.message, '[euphoria]')
15+
16+
steps:
17+
18+
- name: 'Setup/Update Go'
19+
uses: actions/setup-go@v5
20+
with:
21+
go-version: '>=1.22.1'
22+
23+
- name: 'Get Euphoria'
24+
uses: actions/checkout@v4
25+
with:
26+
repository: amnezia-vpn/euphoria
27+
ref: master
28+
path: euphoria
29+
30+
- name: 'Run build script'
31+
working-directory: euphoria
32+
run: |
33+
make
34+
./amneziawg-go --version
35+
36+
- name: 'Archive artifacts'
37+
uses: actions/upload-artifact@v4
38+
with:
39+
name: euphoria-macos
40+
path: euphoria/amneziawg-go
41+
42+
github-release:
43+
name: GitHub Release
44+
needs: Build-Euphoria-MacOS
45+
runs-on: ubuntu-latest
46+
if: startsWith(github.ref, 'refs/tags/')
47+
48+
steps:
49+
- name: Setup | Checkout
50+
uses: actions/checkout@v4
51+
52+
- name: Setup | Artifacts
53+
uses: actions/download-artifact@v4
54+
55+
- name: Setup | Checksums
56+
run: for file in $(find ./ -name '*' ); do openssl dgst -sha256 -r "$file" | awk '{print $1}' > "${file}.sha256"; done
57+
58+
- name: Zip ALL
59+
run: for file in *; do zip -r ${file%.*}.zip $file; done
60+
61+
- name: Upload binaries to release
62+
uses: svenstaro/upload-release-action@v2
63+
with:
64+
repo_token: ${{ secrets.GITHUB_TOKEN }}
65+
file: euphoria-macos.zip
66+
tag: ${{ github.ref }}
67+
overwrite: true
68+
file_glob: true

0 commit comments

Comments
 (0)