Skip to content

update to upload artifact v4 #66

update to upload artifact v4

update to upload artifact v4 #66

Workflow file for this run

name: Build
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
build-linux:
runs-on: ubuntu-22.04
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Install deps
run: sudo apt update && sudo apt install -y libsdl2-dev libnotify-dev
- name: Build on Linux
run: mkdir build && cd build && cmake .. && make -j$(nproc)
- name: Upload linux binary
uses: actions/upload-artifact@v4
with:
name: amd64-binary
path: build/trigger-control
retention-days: 14
build-win:
runs-on: ubuntu-22.04
steps:
- name: Checkout Repository
uses: actions/checkout@v3
- name: Install deps
run: sudo apt update && sudo apt install -y g++-mingw-w64-x86-64 gcc-mingw-w64-x86-64 mingw-w64-tools wget && sudo update-alternatives --set x86_64-w64-mingw32-g++ /usr/bin/x86_64-w64-mingw32-g++-posix
- name: Get SDL2 devel mingw
run: wget https://github.com/libsdl-org/SDL/releases/download/release-2.0.22/SDL2-devel-2.0.22-mingw.tar.gz && tar -xvf SDL2-devel-2.0.22-mingw.tar.gz
- name: Install SDL2
run: sudo mkdir /usr/local/{i686,x86_64}-w64-mingw32 && cd SDL2-2.0.22 && sudo make cross
- name: Build Windows Version
run: mkdir build-win && cd build-win && cmake -DCMAKE_TOOLCHAIN_FILE=../windows.cmake .. && make -j$(nproc)
- name: Upload EXE
uses: actions/upload-artifact@v4
with:
name: win-portable
path: build-win/trigger-control.exe
retention-days: 14