From cee9df832d74674c840fdcb1f1277370282cd44b Mon Sep 17 00:00:00 2001 From: Badcuban <108198679+badcuban@users.noreply.github.com> Date: Mon, 23 Nov 2026 22:59:57 -0500 Subject: [PATCH] chore(ci): replace CodeQL Default Setup with scoped PR and weekly workflow CodeQL Default Setup ran a 20-minute scan on every push to main, scanned .repos/effect, vendored code, tests, and a single C++ test fixture, and stored ~9 GB of overlay database caches that pushed the repository against GitHub's 10 GB cache eviction cap (evicting macOS and Linux desktop release caches). Disabled Default Setup, reclaimed 9.1 GB of old overlay caches, and added a dedicated CodeQL workflow and config that scans javascript-typescript and actions on pull requests and weekly on main while ignoring .repos/, vendored assets, generated files, and tests. --- .github/codeql/codeql-config.yml | 20 +++++++++++++ .github/workflows/codeql.yml | 48 ++++++++++++++++++++++++++++++++ 2 files changed, 68 insertions(+) create mode 100644 .github/codeql/codeql-config.yml create mode 100644 .github/workflows/codeql.yml diff --git a/.github/codeql/codeql-config.yml b/.github/codeql/codeql-config.yml new file mode 100644 index 000000000..96dde6a1b --- /dev/null +++ b/.github/codeql/codeql-config.yml @@ -0,0 +1,20 @@ +name: "Threadlines CodeQL config" + +paths-ignore: + # Read-only Effect 4 source copy for agents (21 MB); not shipped or executed. + - ".repos/**" + # Vendored third-party code. + - "apps/desktop/src/preview/vendor/**" + - "apps/web/public/mockServiceWorker.js" + - "apps/web/src/lib/vendor/**" + # Generated code. + - "**/routeTree.gen.ts" + - "**/worker-configuration.d.ts" + - "packages/effect-codex-app-server/src/_generated/**" + # Test suites and fixtures. + - "**/*.test.*" + - "**/*.spec.*" + - "**/*.browser.*" + - "apps/server/integration/**" + - "apps/server/evals/**" + - "scripts/fixtures/**" diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml new file mode 100644 index 000000000..8582705d6 --- /dev/null +++ b/.github/workflows/codeql.yml @@ -0,0 +1,48 @@ +name: CodeQL + +on: + pull_request: + branches: + - main + schedule: + # Weekly Monday 06:23 UTC (off the :00 cron spike) to keep main's security + # alerts current without running a 20-minute scan on every push to main. + - cron: "23 6 * * 1" + workflow_dispatch: + +permissions: + contents: read + +concurrency: + group: codeql-${{ github.ref }} + cancel-in-progress: ${{ github.event_name == 'pull_request' }} + +jobs: + analyze: + name: Analyze (${{ matrix.language }}) + runs-on: ubuntu-latest + timeout-minutes: 30 + permissions: + actions: read + contents: read + security-events: write + strategy: + fail-fast: false + matrix: + language: + - javascript-typescript + - actions + steps: + - name: Checkout + uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1 + + - name: Initialize CodeQL + uses: github/codeql-action/init@1bd86f2fdb4b86187fa4059f16f31a3202acc9ea # v4.39.4 + with: + languages: ${{ matrix.language }} + config-file: ./.github/codeql/codeql-config.yml + + - name: Perform CodeQL Analysis + uses: github/codeql-action/analyze@1bd86f2fdb4b86187fa4059f16f31a3202acc9ea # v4.39.4 + with: + category: "/language:${{ matrix.language }}"