-
-
Notifications
You must be signed in to change notification settings - Fork 0
40 lines (38 loc) · 1.41 KB
/
build-arm64.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
on:
push:
branches:
- master
workflow_dispatch:
name: Build for arm64
jobs:
build:
runs-on: ubuntu-22.04
steps:
- name: Install Dependencies
run: sudo apt-get install -y gcc-aarch64-linux-gnu libc-dev-arm64-cross
- name: Install toolchain
id: toolchain
uses: dtolnay/rust-toolchain@stable
with:
targets: aarch64-unknown-linux-gnu
- name: Checkout
uses: actions/checkout@v3
- name: Cache
uses: actions/cache@v3
env:
SEGMENT_DOWNLOAD_TIMEOUT_MINS: 10
with:
path: |
target/
~/.cargo/registry/
~/.cargo/git/
key: cargo-${{ runner.os }}-${{ steps.toolchain.outputs.cachekey }}-${{ hashFiles('**/Cargo.lock') }}-${{ github.workflow_sha }}
restore-keys: cargo-${{ runner.os }}-${{ steps.toolchain.outputs.cachekey }}
- name: Compile
run: cargo build --release --target aarch64-unknown-linux-gnu
- name: Upload Binary
uses: actions/upload-artifact@v3
with:
name: preview_bot_arm64
path: target/aarch64-unknown-linux-gnu/release/preview_bot
if-no-files-found: error