Skip to content

Commit

Permalink
Enabled CodeQL (#2158)
Browse files Browse the repository at this point in the history
  • Loading branch information
majastrz committed May 10, 2024
1 parent 43eb865 commit d8b307c
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,10 @@ jobs:
build:
name: "Build"
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

env:
# don't print dotnet logo
Expand All @@ -28,6 +32,11 @@ jobs:
with:
fetch-depth: 0 # avoid shallow clone so nbgv can do its work.

- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: csharp

- name: Setup .NET Core
uses: actions/setup-dotnet@v4

Expand All @@ -52,16 +61,28 @@ jobs:
with:
flags: dotnet

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3

build-generator:
name: "Build Generator"
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # avoid shallow clone so nbgv can do its work.
submodules: recursive

- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: javascript

- name: Setup Node.js
uses: actions/setup-node@v4
with:
Expand All @@ -85,16 +106,28 @@ jobs:
run: npm run build
working-directory: ./src/generator

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3

build-autorest:
name: "Build Autorest.Bicep"
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # avoid shallow clone so nbgv can do its work.
submodules: recursive

- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: javascript

- name: Setup Node.js
uses: actions/setup-node@v4
with:
Expand Down Expand Up @@ -122,3 +155,5 @@ jobs:
run: npm test
working-directory: ./src/autorest.bicep

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3

0 comments on commit d8b307c

Please sign in to comment.