Repository navigation
52 lines (43 loc) · 1.41 KB
/
Copy pathcodeql.yml
File metadata and controls
52 lines (43 loc) · 1.41 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
name: CodeQL
on:
push:
branches: [ "main", "dev" ]
pull_request:
branches: [ "main", "dev" ]
schedule:
- cron: "0 3 * * 1"
# Cancel an in-progress analysis when a newer commit lands on the same ref.
concurrency:
group: codeql-${{ github.ref }}
cancel-in-progress: true
permissions:
contents: read
security-events: write # required to upload the CodeQL results
# actions: read # uncomment if this repository is private
jobs:
analyze:
name: Analyze (Go)
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1
with:
persist-credentials: false
- name: Set up Go (from go.mod)
uses: actions/setup-go@b7ad1dad31e06c5925ef5d2fc7ad053ef454303e
with:
go-version-file: 'go.mod'
cache: false
- name: Initialize CodeQL
uses: github/codeql-action/init@9b3254085494b55a0f7c4c2b3d2d52cc712ce370
with:
languages: go
# The default suite plus lower-precision security queries.
queries: security-extended
# Build the module so CodeQL can trace it (the project's known-good build).
- name: Build
run: go build ./...
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@9b3254085494b55a0f7c4c2b3d2d52cc712ce370
with:
category: "/language:go"