First try at an action
All checks were successful
Build VulkanEngine / build (push) Successful in 3m36s
All checks were successful
Build VulkanEngine / build (push) Successful in 3m36s
This commit is contained in:
parent
6df8188bb8
commit
e4b44af05c
79
.gitea/workflows/build.yaml
Normal file
79
.gitea/workflows/build.yaml
Normal file
@ -0,0 +1,79 @@
|
||||
name: Build VulkanEngine
|
||||
|
||||
on:
|
||||
push:
|
||||
branches:
|
||||
- vkguide
|
||||
pull_request:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: "@weekly"
|
||||
|
||||
jobs:
|
||||
build:
|
||||
runs-on: ubuntu-22.04
|
||||
container: git.alexdelcamp.fr/alexandre_1a/flake-actions:latest
|
||||
|
||||
steps:
|
||||
- name: Checkout (avec submodules récursifs)
|
||||
uses: actions/checkout@v4
|
||||
with:
|
||||
submodules: recursive
|
||||
fetch-depth: 0
|
||||
|
||||
- name: S'assurer que les flakes sont activés
|
||||
run: |
|
||||
mkdir -p ~/.config/nix
|
||||
grep -q "experimental-features" ~/.config/nix/nix.conf 2>/dev/null || \
|
||||
echo "experimental-features = nix-command flakes" >> ~/.config/nix/nix.conf
|
||||
|
||||
- name: Configurer CMake (dans le devShell Nix)
|
||||
run: |
|
||||
nix develop --command bash -c '
|
||||
set -e
|
||||
echo "--- Environnement Nix ---"
|
||||
cmake --version
|
||||
ninja --version
|
||||
echo "--- Configure ---"
|
||||
cmake -S . -B build \
|
||||
-G Ninja \
|
||||
-DCMAKE_BUILD_TYPE=Release \
|
||||
-DCMAKE_EXPORT_COMPILE_COMMANDS=ON
|
||||
'
|
||||
|
||||
- name: Compiler (dans le devShell Nix)
|
||||
run: |
|
||||
nix develop --command bash -c '
|
||||
set -e
|
||||
cmake --build build --parallel "$(nproc)"
|
||||
'
|
||||
|
||||
- name: Lister les binaires produits
|
||||
if: always()
|
||||
run: |
|
||||
echo "=== Contenu de build/ ==="
|
||||
ls -la build/ || true
|
||||
echo "=== Binaires et leurs dépendances runtime ==="
|
||||
find build -maxdepth 2 -type f -executable \( -name "engine" -o -name "server" \) -exec ls -lh {} \; || true
|
||||
echo "=== Contenu de build/engine ==="
|
||||
ls -la build/engine/ || true
|
||||
echo "=== Contenu de build/server ==="
|
||||
ls -la build/server/ || true
|
||||
|
||||
- name: Upload des artefacts
|
||||
if: success()
|
||||
uses: actions/upload-artifact@v3
|
||||
with:
|
||||
name: vulkan-engine
|
||||
path: |
|
||||
build/engine/**
|
||||
build/server/**
|
||||
if-no-files-found: warn
|
||||
|
||||
- name: Notify routine
|
||||
if: always()
|
||||
run: |
|
||||
curl \
|
||||
-H "Title: [Routine] VulkanEngine build" \
|
||||
-d "Build finished (status: ${{ job.status }})" \
|
||||
https://ntfy.alexdelcamp.fr/FlakeBuild
|
||||
Loading…
x
Reference in New Issue
Block a user