forked from WireGuard/wireguard-tools
-
Notifications
You must be signed in to change notification settings - Fork 27
69 lines (53 loc) · 1.78 KB
/
windows-build.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
name: windows-wg
on: [push]
jobs:
Build-Libs-WireGuard-Windows:
name: 'Build-Libs-WireGuard-Windows'
runs-on: windows-latest
steps:
- name: 'Setup ccache'
uses: hendrikmuhs/[email protected]
- name: 'Get sources'
uses: actions/checkout@v3
- name: 'Get Wireguard-Tools'
uses: actions/checkout@v3
with:
repository: amnezia-vpn/amnezia-wg-tools
ref: master
path: windows/wireguard-tools-windows
- name: 'Build WireGuard Tools binary'
working-directory: windows/wireguard-tools-windows
run: |
cmd /c build.cmd
mkdir build
move x64 build\x64
move x86 build\x86
move arm64 build\arm64
- name: Archive WG Windows
uses: actions/upload-artifact@v3
with:
retention-days: 1
name: windows-wireguard-tools
path: windows/wireguard-tools-windows/build
github-release:
name: GitHub Release
needs: Build-Libs-WireGuard-Windows
runs-on: ubuntu-latest
if: startsWith(github.ref, 'refs/tags/')
steps:
- name: Setup | Checkout
uses: actions/checkout@v2
- name: Setup | Artifacts
uses: actions/download-artifact@v2
- name: Setup | Checksums
run: for file in $(find ./ -name '*.exe' ); do openssl dgst -sha256 -r "$file" | awk '{print $1}' > "${file}.sha256"; done
- name: Zip ALL
run: for file in *; do zip -r ${file%.*}.zip $file; done
- name: Upload binaries to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: windows-wireguard-tools.zip
tag: ${{ github.ref }}
overwrite: true
file_glob: true