Skip to content

Commit 876eb18

Browse files
authored
Create build.yml
Signed-off-by: Daniel Maslowski <[email protected]>
1 parent ce56018 commit 876eb18

File tree

1 file changed

+35
-0
lines changed

1 file changed

+35
-0
lines changed

.github/workflows/build.yml

Lines changed: 35 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,35 @@
1+
name: u-root-builder
2+
3+
on:
4+
push:
5+
branches: [ "main" ]
6+
pull_request:
7+
branches: [ "main" ]
8+
9+
jobs:
10+
11+
build:
12+
strategy:
13+
matrix:
14+
template: [core, boot, all, embedded, minimal]
15+
arch: [amd64, arm, arm64, riscv64]
16+
17+
runs-on: ubuntu-latest
18+
steps:
19+
- uses: actions/checkout@v3
20+
with:
21+
repository: u-root/u-root
22+
23+
- name: Set up Go
24+
uses: actions/setup-go@v4
25+
with:
26+
go-version: '1.20'
27+
28+
- name: Build
29+
run:
30+
GOARCH=${{ matrix.arch }} go run . -uroot-source . -o u-root-${{ matrix.arch }}-${{ matrix.template }}.cpio ${{ matrix.template }}
31+
32+
- name: Upload
33+
uses: actions/[email protected]
34+
with:
35+
path: u-root-${{ matrix.arch }}-${{ matrix.template }}.cpio

0 commit comments

Comments
 (0)