Skip to content

Add github workflow that provides build when release #1

Add github workflow that provides build when release

Add github workflow that provides build when release #1

name: C++ Build and Package
on:
release:
types: [created]
jobs:
build:
runs-on: windows-latest
env:

Check failure on line 10 in .github/workflows/build_on_release.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/build_on_release.yml

Invalid workflow file

You have an error in your yaml syntax on line 10
TAG_NAME: ${{ github.ref_name }}
steps:
- uses: actions/checkout@v3
- name: Build (Release)
run: cmake -S ${{github.workspace}}/AimGL -B ${{github.workspace}}/build-release -DCMAKE_BUILD_TYPE=Release
- name: Package (Release)
run: |
cd ${{github.workspace}}/build-release/src/
zip -r release_windows_build_${{ env.TAG_NAME }}.zip ./resources/* *.dll *.exe *.lib
cd ${{github.workspace}}
- name: Build (Debug)
run: cmake -S ${{github.workspace}}/AimGL -B ${{github.workspace}}/build-debug -DCMAKE_BUILD_TYPE=Debug
- name: Package (Debug)
run: |
cd ${{github.workspace}}/build-debug/src/
zip -r debug_windows_build_${{ env.TAG_NAME }}.zip ./resources/* *.dll *.exe *.lib
cd ${{github.workspace}}
- name: Upload Release Artifact
uses: actions/upload-artifact@v2
with:
name: Release Windows Build
path: release_windows_build_${{ env.TAG_NAME }}.zip
- name: Upload Debug Artifact
uses: actions/upload-artifact@v2
with:
name: Debug Windows Build
path: debug_windows_build_${{ env.TAG_NAME }}.zip