-
Notifications
You must be signed in to change notification settings - Fork 2
73 lines (60 loc) · 1.72 KB
/
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
70
71
72
73
name: Publish
on:
workflow_dispatch:
inputs:
openwrt_version:
description: 'OpenWrt version'
default: '23.05.3'
required: true
type: string
env:
CARGO_TERM_COLOR: always
jobs:
build:
name: ${{ matrix.arch }} build
runs-on: ubuntu-latest
strategy:
matrix:
arch:
- arm_arm1176jzf-s_vfp # RPi Zero
- aarch64_cortex-a53 # RPi 3+
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Build
uses: openwrt/gh-action-sdk@main
env:
ARCH: ${{ matrix.arch }}-${{ github.event.inputs.openwrt_version }}
V: sc
PACKAGES: librespot
- name: List outputs
run: |
find bin/packages
- uses: actions/upload-artifact@v4
with:
name: ls-${{ matrix.arch }}
path: bin/packages/${{ matrix.arch }}/action/*.ipk
release:
name: Release all packages
runs-on: ubuntu-latest
needs: build
steps:
- uses: actions/download-artifact@v4
with:
path: ipks
merge-multiple: true
- name: List outputs
id: list
run: |
find ipks
ls ipks | head -n 1 | awk -F"_" '{ print "librespot_version="$2 }' >> "$GITHUB_OUTPUT"
- name: Release
uses: softprops/action-gh-release@v1
with:
prerelease: true
tag_name: v${{ steps.list.outputs.librespot_version }}_${{ github.event.inputs.openwrt_version }}_${{ github.run_number }}
body: |
Librespot v${{ steps.list.outputs.librespot_version }} OpenWrt ${{ github.event.inputs.openwrt_version }} build
files: |
ipks/*