Skip to content

Microsoft C++ Code Analysis #48

Microsoft C++ Code Analysis

Microsoft C++ Code Analysis #48

Workflow file for this run

# This workflow uses actions that are not certified by GitHub.
# They are provided by a third-party and are governed by
# separate terms of service, privacy policy, and support
# documentation.
#
# Find more information at:
# https://github.com/microsoft/msvc-code-analysis-action
name: Microsoft C++ Code Analysis
on:
push:
branches: [ "master" ]
tags:
- '*'
pull_request:
branches: [ "master" ]
schedule:
- cron: '25 23 * * 2'
env:
# Path to the CMake build directory.
project_zip_path: '${{ github.workspace }}\install\mylib.zip'
build: '${{ github.workspace }}\build'
install_location: '${{ github.workspace }}\install\*'
permissions:
contents: write
jobs:
build:
permissions:
contents: write # for actions/checkout to fetch code
security-events: write # for github/codeql-action/upload-sarif to upload SARIF results
actions: write # only required for a private repository by github/codeql-action/upload-sarif to get the Action run status
name: Build
runs-on: self-hosted
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Configure CMake
run: cmake -B ${{ env.build }} -DCMAKE_BUILD_TYPE=Release
- name: CMake Build&Install
run: cmake --build ${{ env.build }} --target install --config Release
- name: Pack
run: 7z a ${{ env.project_zip_path }} ${{ env.install_location }}
- name: Upload binaries to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: ${{ env.project_zip_path }}
asset_name: mylib.zip
tag: ${{ github.ref }}
overwrite: true
body: "This is my release text"