mirror of
https://github.com/github/codeql-action.git
synced 2026-05-23 14:28:45 +00:00
60 lines
1.6 KiB
YAML
60 lines
1.6 KiB
YAML
name: PR Checks (Basic Checks and Runner)
|
|
|
|
on:
|
|
push:
|
|
branches: [main, v1]
|
|
pull_request:
|
|
# Run checks on reopened draft PRs to support triggering PR checks on draft PRs that were opened
|
|
# by other workflows.
|
|
types: [opened, synchronize, reopened, ready_for_review]
|
|
workflow_dispatch:
|
|
|
|
jobs:
|
|
runner-analyze-csharp-autobuild-macos:
|
|
name: Runner macos autobuild C# analyze
|
|
runs-on: macos-latest
|
|
|
|
steps:
|
|
- uses: actions/checkout@v2
|
|
|
|
- name: Move codeql-action
|
|
shell: bash
|
|
run: |
|
|
mkdir ../action
|
|
mv * .github ../action/
|
|
mv ../action/tests/multi-language-repo/{*,.github} .
|
|
mv ../action/.github/workflows .github
|
|
|
|
- name: Build runner
|
|
run: |
|
|
cd ../action/runner
|
|
npm install
|
|
npm run build-runner
|
|
|
|
- name: Initialize dotnet
|
|
run: dotnet restore
|
|
|
|
- name: Run init
|
|
run: |
|
|
../action/runner/dist/codeql-runner-macos init --repository $GITHUB_REPOSITORY --languages csharp --github-url $GITHUB_SERVER_URL --github-auth ${{ github.token }}
|
|
|
|
- name: Build code
|
|
shell: bash
|
|
run: |
|
|
rm build.sh
|
|
../action/runner/dist/codeql-runner-macos autobuild
|
|
|
|
- name: Run analyze
|
|
run: |
|
|
../action/runner/dist/codeql-runner-macos analyze --repository $GITHUB_REPOSITORY --commit $GITHUB_SHA --ref $GITHUB_REF --github-url $GITHUB_SERVER_URL --github-auth ${{ github.token }}
|
|
env:
|
|
TEST_MODE: true
|
|
|
|
- uses: actions/upload-artifact@v2
|
|
if: always()
|
|
with:
|
|
name: my-artifact
|
|
path: |
|
|
bin
|
|
obj
|