CI #36
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
push: | |
pull_request: | |
workflow_dispatch: | |
release: | |
types: [published] | |
env: | |
PROJECT_TYPE: TOOL | |
jobs: | |
build: | |
name: Build | |
runs-on: macos-latest | |
env: | |
JOB_TYPE: BUILD | |
steps: | |
- uses: actions/checkout@v3 | |
with: | |
path: gfxutil | |
- uses: actions/checkout@v3 | |
with: | |
repository: acidanthera/audk | |
path: edk2 | |
- name: CI Bootstrap | |
run: | | |
cd gfxutil; src=$(/usr/bin/curl -Lfs https://raw.githubusercontent.com/acidanthera/ocbuild/master/ci-bootstrap.sh) && eval "$src" || exit 1 | |
- run: cd gfxutil; xcodebuild -project gfxutil.xcodeproj -jobs 1 -configuration Debug | |
- run: cd gfxutil; xcodebuild -project gfxutil.xcodeproj -jobs 1 -configuration Release | |
- name: Upload to Artifacts | |
uses: actions/upload-artifact@v3 | |
with: | |
name: Artifacts | |
path: gfxutil/build/*/*.zip | |
- name: Upload to Release | |
if: github.event_name == 'release' | |
uses: svenstaro/upload-release-action@e74ff71f7d8a4c4745b560a485cc5fdb9b5b999d | |
with: | |
repo_token: ${{ secrets.GITHUB_TOKEN }} | |
file: gfxutil/build/*/*.zip | |
tag: ${{ github.ref }} | |
file_glob: true | |
# TODO: Reenable once clang analyzer stops reporting false postitives or we find a way to silence warnings without editing the source code. | |
# analyze-clang: | |
# name: Analyze Clang | |
# runs-on: macos-latest | |
# env: | |
# JOB_TYPE: ANALYZE | |
# steps: | |
# - uses: actions/checkout@v3 | |
# with: | |
# path: gfxutil | |
# - uses: actions/checkout@v3 | |
# with: | |
# repository: acidanthera/audk | |
# path: edk2 | |
# - name: CI Bootstrap | |
# run: | | |
# cd gfxutil; src=$(/usr/bin/curl -Lfs https://raw.githubusercontent.com/acidanthera/ocbuild/master/ci-bootstrap.sh) && eval "$src" || exit 1 | |
# | |
# - run: cd gfxutil; xcodebuild -project gfxutil.xcodeproj analyze -quiet -scheme gfxutil -configuration Debug CLANG_ANALYZER_OUTPUT=plist-html CLANG_ANALYZER_OUTPUT_DIR="$(pwd)/clang-analyze" && [ "$(find clang-analyze -name "*.html")" = "" ] | |
# - run: cd gfxutil; xcodebuild -project gfxutil.xcodeproj analyze -quiet -scheme gfxutil -configuration Release CLANG_ANALYZER_OUTPUT=plist-html CLANG_ANALYZER_OUTPUT_DIR="$(pwd)/clang-analyze" && [ "$(find clang-analyze -name "*.html")" = "" ] | |
# | |
# analyze-coverity: | |
# name: Analyze Coverity | |
# runs-on: macos-latest | |
# env: | |
# JOB_TYPE: COVERITY | |
# if: github.repository_owner == 'acidanthera' && github.event_name != 'pull_request' | |
# steps: | |
# - uses: actions/checkout@v3 | |
# with: | |
# path: gfxutil | |
# - uses: actions/checkout@v3 | |
# with: | |
# repository: acidanthera/audk | |
# path: edk2 | |
# - name: CI Bootstrap | |
# run: | | |
# cd gfxutil; src=$(/usr/bin/curl -Lfs https://raw.githubusercontent.com/acidanthera/ocbuild/master/ci-bootstrap.sh) && eval "$src" || exit 1 | |
# | |
# - name: Run Coverity | |
# run: | | |
# cd gfxutil; src=$(/usr/bin/curl -Lfs https://raw.githubusercontent.com/acidanthera/ocbuild/master/coverity/covstrap.sh) && eval "$src" || exit 1 | |
# env: | |
# COVERITY_SCAN_TOKEN: ${{ secrets.COVERITY_SCAN_TOKEN }} | |
# COVERITY_SCAN_EMAIL: ${{ secrets.COVERITY_SCAN_EMAIL }} | |
# COVERITY_BUILD_COMMAND: xcodebuild -project gfxutil.xcodeproj -configuration Release |