-
Notifications
You must be signed in to change notification settings - Fork 1
67 lines (57 loc) · 1.87 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
name: archlinux arm build nightly
on:
repository_dispatch:
workflow_dispatch:
push:
pull_request:
schedule:
- cron: '0 0 * * *'
jobs:
build:
strategy:
matrix:
os: [ubuntu-latest]
name: Test on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v3
- name: Setup variables
run: |
echo RELEASE=$(date +%Y\/%m\/%d) >> $GITHUB_ENV
- name: Install dependencies
run: |
sudo apt update
sudo apt install make mkbootimg build-essential \
libncurses5-dev bison flex libssl-dev device-tree-compiler \
gcc-arm-none-eabi gcc-aarch64-linux-gnu bc libfdt-dev \
libarchive-tools arch-install-scripts qemu-user-static
- name: Initialization submodule
run: git submodule update --init --depth=1
- name: Build packets
run: sudo bash ${{github.workspace}}/build.sh
- name: Create release
uses: softprops/action-gh-release@v1
if: github.ref == 'refs/heads/master'
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
with:
body: ${{env.RELEASE}}
tag_name: ${{env.RELEASE}}
draft: false
prerelease: false
files: |
${{github.workspace}}/build/aboot.img
${{github.workspace}}/build/boot.img
${{github.workspace}}/build/rootfs.img.zst
${{github.workspace}}/build/aboot.img.sha256sum
${{github.workspace}}/build/boot.img.sha256sum
${{github.workspace}}/build/rootfs.img.zst.sha256sum
- name: Delete old releases
uses: dev-drprasad/[email protected]
if: github.ref == 'refs/heads/master'
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}
with:
keep_latest: 1
delete_tags: true