Skip to content

Commit 15254d2

Browse files
committed
codeql workflow
1 parent 618d22a commit 15254d2

File tree

2 files changed

+28
-92
lines changed

2 files changed

+28
-92
lines changed

.github/workflows/codeql-analysis.yml

Lines changed: 28 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -24,15 +24,26 @@ on:
2424
jobs:
2525
analyze:
2626
name: Analyze
27-
runs-on: ubuntu-latest
27+
# Runner size impacts CodeQL analysis time. To learn more, please see:
28+
# - https://gh.io/recommended-hardware-resources-for-running-codeql
29+
# - https://gh.io/supported-runners-and-hardware-resources
30+
# - https://gh.io/using-larger-runners
31+
# Consider using larger runners for possible analysis time improvements.
32+
runs-on: ${{ (matrix.language == 'swift' && 'macos-latest') || 'ubuntu-latest' }}
33+
timeout-minutes: ${{ (matrix.language == 'swift' && 120) || 360 }}
34+
permissions:
35+
actions: read
36+
contents: read
37+
security-events: write
2838

2939
strategy:
3040
fail-fast: false
3141
matrix:
3242
language: [ 'csharp' ]
33-
# CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python' ]
34-
# Learn more...
35-
# https://docs.github.com/en/github/finding-security-vulnerabilities-and-errors-in-your-code/configuring-code-scanning#overriding-automatic-language-detection
43+
# CodeQL supports [ 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'swift' ]
44+
# Use only 'java-kotlin' to analyze code written in Java, Kotlin or both
45+
# Use only 'javascript-typescript' to analyze code written in JavaScript, TypeScript or both
46+
# Learn more about CodeQL language support at https://aka.ms/codeql-docs/language-support
3647

3748
steps:
3849
- name: Checkout repository
@@ -46,23 +57,30 @@ jobs:
4657
# If you wish to specify custom queries, you can do so here or in a config file.
4758
# By default, queries listed here will override any specified in a config file.
4859
# Prefix the list here with "+" to use these queries and those in the config file.
49-
# queries: ./path/to/local/query, your-org/your-repo/queries@main
5060

51-
# Autobuild attempts to build any compiled languages (C/C++, C#, or Java).
61+
# For more details on CodeQL's query packs, refer to: https://docs.github.com/en/code-security/code-scanning/automatically-scanning-your-code-for-vulnerabilities-and-errors/configuring-code-scanning#using-queries-in-ql-packs
62+
# queries: security-extended,security-and-quality
63+
64+
# Autobuild attempts to build any compiled languages (C/C++, C#, Go, Java, or Swift).
5265
# If this step fails, then you should remove it and run the build manually (see below)
5366
- name: Autobuild
5467
uses: github/codeql-action/autobuild@v2
5568

5669
# ℹ️ Command-line programs to run using the OS shell.
57-
# 📚 https://git.io/JvXDl
70+
# 📚 See https://docs.github.com/en/actions/using-workflows/workflow-syntax-for-github-actions#jobsjob_idstepsrun
71+
72+
# If the Autobuild fails above, remove it and uncomment the following three lines.
73+
# modify them (or add more) to build your code if your project, please refer to the EXAMPLE below for guidance.
5874

59-
# ✏️ If the Autobuild fails above, remove it and uncomment the following three lines
60-
# and modify them (or add more) to build your code if your project
61-
# uses a compiled language
75+
# - run: |
76+
# echo "Run, Build Application using script"
77+
# ./location_of_script_within_repo/buildscript.sh
6278

6379
#- run: |
6480
# make bootstrap
6581
# make release
6682

6783
- name: Perform CodeQL Analysis
6884
uses: github/codeql-action/analyze@v2
85+
with:
86+
category: "/language:${{matrix.language}}"

.github/workflows/codeql.yml

Lines changed: 0 additions & 82 deletions
This file was deleted.

0 commit comments

Comments
 (0)