Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

cFS Integration candidate: 2021-07-27 #313

Merged
merged 8 commits into from
Aug 3, 2021
Next Next commit
Fix #264, CodeQL Dependent on Successful Build
  • Loading branch information
arielswalker committed Jul 20, 2021
commit a1464366e5f74b217c4a4e583850bdd50311fd0b
23 changes: 17 additions & 6 deletions .github/workflows/codeql-build.yml
Original file line number Diff line number Diff line change
@@ -1,24 +1,28 @@
name: "CodeQL Analysis"

# Only trigger, when the build workflow succeeded
on:
push:
pull_request:
branches:
- main

workflow_run:
workflows: ["Build, Test, and Run \\[OMIT_DEPRECATED=true\\]"]
types:
- completed
branches:
- '**'
env:
SIMULATION: native
ENABLE_UNIT_TESTS: true
OMIT_DEPRECATED: true
BUILDTYPE: release


jobs:
#Checks for duplicate actions. Skips push actions if there is a matching or duplicate pull-request action.
check-for-duplicates:
runs-on: ubuntu-latest
# Map a step output to a job output
outputs:
should_skip: ${{ steps.skip_check.outputs.should_skip }}
if: ${{ github.event.workflow_run.conclusion == 'success' }}
steps:
- id: skip_check
uses: fkirc/skip-duplicate-actions@master
Expand Down Expand Up @@ -117,7 +121,7 @@ jobs:
run: |
cp ./cfe/cmake/Makefile.sample Makefile
cp -r ./cfe/cmake/sample_defs sample_defs

# Setup the build system
- name: Make Install
if: ${{ !steps.skip-workflow.outputs.skip }}
Expand All @@ -127,3 +131,10 @@ jobs:
- name: Perform CodeQL Analysis
if: ${{ !steps.skip-workflow.outputs.skip }}
uses: github/codeql-action/analyze@v1

on-failure:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'failure' }}
steps:
- name: Fail workflow
run: exit 1