perlin-shadows/.forgejo/workflows/build.yaml
Michael Bradley 7f987925b1
Some checks failed
Build / Format (push) Failing after 21s
Build / Build (push) Successful in 38s
Fix executable name for real this time
2025-02-23 12:58:58 -05:00

38 lines
1 KiB
YAML

---
on: [push]
name: Build
jobs:
format:
name: Format
runs-on: ubuntu-22.04
steps:
- name: Check out the code
uses: actions/checkout@v4
- name: Install clang-format
run: |
sudo apt-get update
sudo apt-get -y install clang-format
- name: Check the code's formatting
run: "clang-format --dry-run src/*.h src/*.cpp 2>&1 | tee fmt.log; [ ! -s fmt.log ]"
build:
name: Build
runs-on: ubuntu-22.04
steps:
- name: Check out the code
uses: actions/checkout@v4
- name: Install the toolchain
run: |
sudo apt-get update
sudo apt-get -y install cmake freeglut3-dev libglew-dev libglm-dev
- name: Set up the build environment
run: cmake -S . -B cmake-build-debug -DCMAKE_EXPORT_COMPILE_COMMANDS=ON
- name: Compile the code
run: cmake --build cmake-build-debug
- name: Save executable
uses: forgejo/upload-artifact@v4
with:
name: bin.zip
path: cmake-build-debug/perlin-shadows