Github workflow
All checks were successful
Build / Check format (push) Successful in 41s
Build / Build pacwrap (push) Successful in 1m36s

This commit is contained in:
Xavier Moffett 2024-10-06 20:32:18 -04:00
parent 878db06495
commit 1c66a7e4a4
Signed by: Sapphirus
GPG key ID: A6C061B2CEA1A7AC

56
.github/workflows/build.yml vendored Normal file
View file

@ -0,0 +1,56 @@
name: Build
on:
workflow_dispatch:
pull_request:
types:
- opened
branches:
- master
env:
CARGO_TERM_COLOR: always
PACWRAP_SCHEMA_BUILT: 1
PACWRAP_CI: 1
jobs:
checkfmt:
name: Check format
runs-on: ubuntu-latest
container:
image: archlinux
strategy:
matrix:
toolchain:
- nightly
steps:
- name: Install packages
run: pacman -Syu git nodejs rustup --noconfirm
- name: Checkout repository
uses: actions/checkout@v4
- name: Install toolchain
run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
- name: Check format
run: cargo fmt --check
build:
name: Build pacwrap
runs-on: ubuntu-latest
container:
image: archlinux
strategy:
matrix:
toolchain:
- stable
steps:
- name: Install packages
run: pacman -Syu base-devel bubblewrap busybox fakechroot fakeroot git nodejs rustup --noconfirm
- name: Checkout repository
uses: actions/checkout@v4
- name: Install toolchain
run: rustup update ${{ matrix.toolchain }} && rustup default ${{ matrix.toolchain }}
- name: Set up environment
run: git config --global --add safe.directory '*'
- name: Build pacwrap
run: ./dist/tools/prepare.sh release && cargo build --release && ./dist/tools/package.sh release
- name: Lint pacwrap
run: cargo clippy --release -- -Dwarnings