forked from msys2/setup-msys2
-
Notifications
You must be signed in to change notification settings - Fork 0
100 lines (84 loc) · 2.3 KB
/
pkgbuild.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
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
name: Example PKGBUILD
on:
push:
pull_request:
schedule:
- cron: '0 0 * * 3'
workflow_dispatch:
jobs:
win-makepkg:
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
include:
- { icon: '⬛', sys: mingw32 }
- { icon: '🟦', sys: mingw64 }
- { icon: '🟨', sys: ucrt64 } # Experimental!
- { icon: '🟧', sys: clang64 } # Experimental!
name: 🚧${{ matrix.icon }} ${{ matrix.sys }} | makepkg
defaults:
run:
shell: msys2 {0}
env:
MINGW_ARCH: ${{ matrix.sys }}
steps:
- name: '⚙️ git config'
run: git config --global core.autocrlf input
shell: bash
- name: '🧰 Checkout'
uses: actions/checkout@v2
with:
fetch-depth: 0
- name: '${{ matrix.icon }} Setup MSYS2'
uses: msys2/setup-msys2@v2
with:
msystem: ${{ matrix.sys }}
update: true
install: git base-devel tree
pacboy: toolchain:p
- name: '🚧 Build package'
run: |
cd examples/pkgbuild
makepkg-mingw --noconfirm --noprogressbar -sCLf
- name: '📤 Upload artifact: package'
uses: actions/upload-artifact@v2
with:
name: ${{ matrix.sys }}-TOOL
path: examples/pkgbuild/*.zst
- name: '🔍 Show package content'
run: |
mkdir tmp
cd tmp
tar -xf ../examples/pkgbuild/*.zst
tree .
win-test:
needs: win-makepkg
runs-on: windows-latest
strategy:
fail-fast: false
matrix:
include:
- { icon: '⬛', sys: mingw32 }
- { icon: '🟦', sys: mingw64 }
- { icon: '🟨', sys: ucrt64 } # Experimental!
- { icon: '🟧', sys: clang64 } # Experimental!
name: 🚦${{ matrix.icon }} ${{ matrix.sys }} | test
defaults:
run:
shell: msys2 {0}
steps:
- name: '${{ matrix.icon }} Setup MSYS2'
uses: msys2/setup-msys2@v2
with:
msystem: ${{ matrix.sys }}
update: true
- name: '📥 Download artifact: package'
uses: actions/download-artifact@v2
with:
path: .
name: ${{ matrix.sys }}-TOOL
- name: '🛠️ Install package'
run: pacman -U --noconfirm --noprogressbar *.zst
- name: '🚦 Test package'
run: TOOL