Skip to content

Add CodeQL analysis workflow for security scanning #7

Add CodeQL analysis workflow for security scanning

Add CodeQL analysis workflow for security scanning #7

Workflow file for this run

name: CodeQL Analysis
on:
push:
branches: [ main ]
pull_request:
branches: [ main ]
jobs:
analyze:
name: Analyze CodeQL
runs-on: macos-latest
permissions:
security-events: write
actions: read
contents: read
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
languages: swift
queries: security-and-quality
# Build the Swift package
- name: Build Swift package
run: swift build
- name: Perform CodeQL Analysis
uses: github/codeql-action/analyze@v2
with:
category: "/language:swift"