Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
65 changes: 65 additions & 0 deletions .github/workflows/codeql.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
name: CodeQL

on:
push:
branches: [main, dev]
pull_request:
branches: [main, dev]
schedule:
- cron: "23 5 * * 1"

jobs:
analyze:
name: Analyze (${{ matrix.language }})
runs-on: ubuntu-latest
permissions:
actions: read
contents: read
security-events: write

strategy:
fail-fast: false
matrix:
include:
- language: go
build-mode: manual
- language: javascript-typescript
build-mode: none

steps:
- name: Checkout
uses: actions/checkout@v5

- name: Set up Go
if: matrix.language == 'go'
uses: actions/setup-go@v6
with:
go-version: "1.25"

- name: Install swag
if: matrix.language == 'go'
run: go install github.com/swaggo/swag/cmd/swag@latest

- name: Generate Swagger docs
if: matrix.language == 'go'
working-directory: backend
run: swag init -d cmd/server,internal/api -g main.go --parseDependency --parseInternal -o docs

- name: Initialize CodeQL
uses: github/codeql-action/init@v3
with:
languages: ${{ matrix.language }}
build-mode: ${{ matrix.build-mode }}

# The Go module lives in backend/ and its swagger docs package is
# generated above. Autobuild cannot locate the module from the repo
# root, so build explicitly from backend/ here.
- name: Build Go
if: matrix.language == 'go'
working-directory: backend
run: go build ./...

- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v3
with:
category: "/language:${{ matrix.language }}"
Loading