2021-07-28 23:49:17 +00:00
|
|
|
name: Coverity
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
2021-09-28 15:03:36 +00:00
|
|
|
branches: [master]
|
2021-07-28 23:49:17 +00:00
|
|
|
paths-ignore:
|
|
|
|
- '.gitignore'
|
|
|
|
- '.gitattributes'
|
|
|
|
- 'res/**'
|
|
|
|
- '**.cmd'
|
|
|
|
- '**.md'
|
|
|
|
- '**.rc'
|
|
|
|
- '**.sh'
|
|
|
|
- '**.txt'
|
|
|
|
- '**.xml'
|
|
|
|
|
|
|
|
env:
|
|
|
|
SOLUTION_FILE_PATH: ./rufus.sln
|
|
|
|
EMAIL: pete@akeo.ie
|
2021-09-07 22:39:04 +00:00
|
|
|
BUILD_CONFIGURATION: Release
|
2021-09-07 00:01:56 +00:00
|
|
|
TARGET_PLATFORM: x64
|
|
|
|
COVERITY_PROJECT_NAME: pbatard%2Frufus
|
2021-07-28 23:49:17 +00:00
|
|
|
|
|
|
|
jobs:
|
2021-09-03 23:55:59 +00:00
|
|
|
Coverity-Build:
|
2022-07-25 15:48:57 +00:00
|
|
|
runs-on: windows-latest
|
2021-07-28 23:49:17 +00:00
|
|
|
|
|
|
|
steps:
|
|
|
|
- name: Checkout repository
|
2023-09-05 11:38:05 +00:00
|
|
|
uses: actions/checkout@v4
|
2021-07-28 23:49:17 +00:00
|
|
|
with:
|
|
|
|
fetch-depth: 0
|
|
|
|
submodules: recursive
|
|
|
|
|
|
|
|
- name: Download Coverity
|
|
|
|
run: |
|
2021-09-07 00:01:56 +00:00
|
|
|
curl -d "token=${{ secrets.COVERITY_SCAN_TOKEN }}&project=${{ env.COVERITY_PROJECT_NAME }}" -L https://scan.coverity.com/download/cxx/win64 -o cov-analysis-win64.zip
|
2021-07-28 23:49:17 +00:00
|
|
|
7z x cov-analysis-win64.zip
|
|
|
|
del cov-analysis-win64.zip
|
|
|
|
move cov-analysis-win64* cov-analysis-win64
|
|
|
|
|
|
|
|
- name: Add Coverity to PATH
|
|
|
|
shell: bash
|
|
|
|
run: echo "${{github.workspace}}/cov-analysis-win64/bin" >> $GITHUB_PATH
|
|
|
|
|
|
|
|
- name: Add MSBuild to PATH
|
2022-12-15 17:40:02 +00:00
|
|
|
uses: microsoft/setup-msbuild@v1
|
2021-07-28 23:49:17 +00:00
|
|
|
|
|
|
|
- name: Build with Coverity
|
2022-02-18 17:18:34 +00:00
|
|
|
run: |
|
|
|
|
cov-configure --msvc
|
|
|
|
cov-build.exe --dir cov-int msbuild ${{ env.SOLUTION_FILE_PATH }} /m /p:Configuration=${{ env.BUILD_CONFIGURATION }},Platform=${{ env.TARGET_PLATFORM }}
|
2022-01-07 13:25:46 +00:00
|
|
|
|
|
|
|
- name: Publish Coverity artifacts
|
2022-06-23 13:26:39 +00:00
|
|
|
uses: actions/upload-artifact@v3
|
2022-01-07 13:25:46 +00:00
|
|
|
with:
|
|
|
|
name: cov-int
|
|
|
|
path: cov-int/
|
2021-07-28 23:49:17 +00:00
|
|
|
|
|
|
|
- name: Upload Coverity build for analysis
|
|
|
|
run: |
|
|
|
|
7z a -r cov-int.zip cov-int
|
2021-09-07 00:01:56 +00:00
|
|
|
curl --form email=${{ env.EMAIL }} --form token=${{ secrets.COVERITY_SCAN_TOKEN }} --form file=@cov-int.zip --form version="${{ env.GITHUB_SHA }}" --form description="Automated build" https://scan.coverity.com/builds?project=${{ env.COVERITY_PROJECT_NAME }}
|
2022-01-07 13:25:46 +00:00
|
|
|
|