diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 00000000..7468b9ad --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,37 @@ +name: Release + +on: + push: + tags: + - 'v*' # Push events to matching v*, i.e. v1.0, v20.15.10 + +env: + BUILD_TYPE: Debug + +jobs: + release: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v3 + with: + submodules: recursive + + - name: Configure CMake + run: cmake -B ${{github.workspace}}/build -DCMAKE_BUILD_TYPE=${{env.BUILD_TYPE}} + + - name: Build + # Build your program with the given configuration + run: cmake --build ${{github.workspace}}/build --config ${{env.BUILD_TYPE}} --target release + + - name: 'Upload Artifact' + uses: actions/upload-artifact@v3 + with: + name: cib.hpp + path: build/cib.hpp + + - name: Release + uses: softprops/action-gh-release@v0.1.14 + with: + files: build/cib.hpp + + diff --git a/.github/workflows/unit_tests.yml b/.github/workflows/unit_tests.yml index 206cd70e..ad64c2a4 100644 --- a/.github/workflows/unit_tests.yml +++ b/.github/workflows/unit_tests.yml @@ -70,7 +70,7 @@ jobs: # See https://cmake.org/cmake/help/latest/manual/ctest.1.html for more detail run: ctest -C ${{env.BUILD_TYPE}} - release: + build_single_header: needs: build_and_test runs-on: ubuntu-latest steps: @@ -91,10 +91,5 @@ jobs: name: cib.hpp path: build/cib.hpp - - name: Release - uses: softprops/action-gh-release@v0.1.14 - if: startsWith(github.ref, 'refs/tags/') - with: - files: build/cib.hpp