56 lines
1.2 KiB
YAML
56 lines
1.2 KiB
YAML
name: Build
|
|
|
|
on:
|
|
push:
|
|
branches:
|
|
- '*'
|
|
pull_request:
|
|
branches:
|
|
- '*'
|
|
|
|
jobs:
|
|
build-arch:
|
|
runs-on: ubuntu-latest
|
|
container:
|
|
image: archlinux:latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: Install dependencies
|
|
run: |
|
|
pacman -Syu --noconfirm base-devel rust
|
|
useradd builder -m -G wheel
|
|
echo 'builder ALL=(ALL) NOPASSWD: ALL' >> /etc/sudoers
|
|
|
|
- name: Build Arch package
|
|
run: |
|
|
chown -R builder:builder .
|
|
cd build/arch
|
|
sudo -u builder bash -c "makepkg -sf --noconfirm"
|
|
|
|
- name: Print current directory
|
|
run: ls -la
|
|
|
|
- name: Upload Arch package
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: pokerust.pkg.tar.zst
|
|
path: ./**/*.pkg.tar.zst
|
|
|
|
build:
|
|
runs-on: ubuntu-latest
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: Install dependencies
|
|
run: sudo apt-get install -y dpkg-dev
|
|
|
|
- name: Build Debian package
|
|
run: sh build/debian/debian.sh
|
|
|
|
- name: Upload Debian package
|
|
uses: actions/upload-artifact@v2
|
|
with:
|
|
name: pokerust.deb
|
|
path: ./build/debian/pokerust.deb
|