84 lines
1.8 KiB
YAML
84 lines
1.8 KiB
YAML
name: Build on Multiple Distributions
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- main
|
|
pull_request:
|
|
branches:
|
|
- main
|
|
|
|
jobs:
|
|
build-on-arch:
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: archlinux:latest
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
pacman -Syu --noconfirm
|
|
pacman -S --noconfirm git rustup gcc
|
|
rustup default stable
|
|
|
|
- name: Build with cargo
|
|
run: |
|
|
cargo build --release
|
|
|
|
- name: Upload artifact
|
|
uses: actions/upload-artifact@v3
|
|
with:
|
|
name: arch-setup
|
|
path: target/release/setup
|
|
|
|
build-on-debian:
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: debian:stable
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
apt update && apt upgrade -y
|
|
apt install -y git curl
|
|
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
|
|
. $HOME/.cargo/env
|
|
|
|
- name: Build with cargo
|
|
run: |
|
|
cargo build --release
|
|
|
|
- name: Upload artifact
|
|
uses: actions/upload-artifact@v3
|
|
with:
|
|
name: debian-setup
|
|
path: target/release/setup
|
|
|
|
build-on-fedora:
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: fedora:latest
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
dnf update -y
|
|
dnf install -y git curl
|
|
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y
|
|
. $HOME/.cargo/env
|
|
|
|
- name: Build with cargo
|
|
run: |
|
|
cargo build --release
|
|
|
|
- name: Upload artifact
|
|
uses: actions/upload-artifact@v3
|
|
with:
|
|
name: fedora-setup
|
|
path: target/release/setup |