Skip to content

Commit

Permalink
Upload build logs as artifacts if failure.
Browse files Browse the repository at this point in the history
  • Loading branch information
nmoinvaz committed Feb 14, 2021
1 parent 92e3dd0 commit 9640527
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 0 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/cmake.yml
Original file line number Diff line number Diff line change
Expand Up @@ -379,11 +379,29 @@ jobs:
LDFLAGS: ${{ matrix.ldflags }}
CI: true

- name: Generate project files (artifacts)
uses: actions/upload-artifact@v2
if: failure()
with:
name: ${{ matrix.name }} (cmake)
path: |
CMakeFiles/CMakeOutput.log
CMakeFiles/CMakeError.log
- name: Compile source code
run: |
cd ${{ matrix.build-dir || '.' }}
cmake --build . --config ${{ matrix.build-config || 'Release' }}
- name: Compile source code (artifacts)
uses: actions/upload-artifact@v2
if: failure()
with:
name: ${{ matrix.name }} (cmake-build)
path: |
CMakeFiles/CMakeOutput.log
CMakeFiles/CMakeError.log
- name: Run test cases
# Don't run tests on Windows ARM
if: runner.os != 'Windows' || contains(matrix.name, 'ARM') == false
Expand Down
7 changes: 7 additions & 0 deletions .github/workflows/configure.yml
Original file line number Diff line number Diff line change
Expand Up @@ -190,6 +190,13 @@ jobs:
CHOST: ${{ matrix.chost }}
CI: true

- name: Generate project files (artifacts)
uses: actions/upload-artifact@v2
if: failure()
with:
name: ${{ matrix.name }} (configure)
path: configure.log

- name: Compile source code
run: |
cd ${{ matrix.build-dir || '.' }}
Expand Down

0 comments on commit 9640527

Please sign in to comment.