Improve OsPlugin reliability: proactive OS retrieval, unload handling, and session caching #3835
Workflow file for this run
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # For most projects, this workflow file will not need changing; you simply need | |
| # to commit it to your repository. | |
| # | |
| # You may wish to alter this file to override the set of languages analyzed, | |
| # or to provide custom queries or build logic. | |
| # | |
| # ******** NOTE ******** | |
| # We have attempted to detect the languages in your repository. Please check | |
| # the `language` matrix defined below to confirm you have the correct set of | |
| # supported CodeQL languages. | |
| # | |
| name: "CodeQL" | |
| on: | |
| push: | |
| branches: [ "main", "master", "beta", "Release*", "release*", "*-legacy", "legacy-v1" ] | |
| pull_request: | |
| # The branches below must be a subset of the branches above | |
| branches: [ "main", "master", "beta", "Release*", "release*", "*-legacy", "legacy-v1" ] | |
| schedule: | |
| - cron: '15 17 * * 2' # Every Tuesday at 17:15 UTC | |
| jobs: | |
| analyze: | |
| name: Analyze (${{ matrix.language }}) | |
| runs-on: ubuntu-latest | |
| permissions: | |
| # required for all workflows | |
| security-events: write | |
| # required to fetch internal or private CodeQL packs | |
| packages: read | |
| # only required for workflows in private repositories | |
| actions: read | |
| contents: read | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| include: | |
| - language: actions | |
| - language: javascript | |
| - language: javascript-typescript | |
| node-version: '18' | |
| # CodeQL supports the following values keywords for 'language': 'actions', 'c-cpp', 'csharp', 'go', 'java-kotlin', 'javascript-typescript', 'python', 'ruby', 'swift' | |
| # Use `c-cpp` to analyze code written in C, C++ or both | |
| # Use 'java-kotlin' to analyze code written in Java, Kotlin or both | |
| # Use 'javascript-typescript' to analyze code written in JavaScript, TypeScript or both | |
| # To learn more about changing the languages that are analyzed or customizing the build mode for your analysis, | |
| # see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/customizing-your-advanced-setup-for-code-scanning. | |
| # If you are analyzing a compiled language, you can modify the 'build-mode' for that language to customize how | |
| # your codebase is analyzed, see https://docs.github.com/en/code-security/code-scanning/creating-an-advanced-setup-for-code-scanning/codeql-code-scanning-for-compiled-languages | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| # Setup Node.js for JavaScript projects | |
| - name: Setup Node.js ${{ matrix.node-version }} | |
| # Only run the build for Typescript/JavaScript language match | |
| if: matrix.language == 'javascript-typescript' | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: ${{ matrix.node-version }} | |
| # Install dependencies for JavaScript projects | |
| - name: Install dependencies | |
| # Only run the build for Typescript/JavaScript language match | |
| if: matrix.language == 'javascript-typescript' | |
| run: | | |
| node common/scripts/install-run-rush.js update --full --recheck | |
| npm install rollup -g | |
| npm install grunt-cli | |
| npm install | |
| node common/scripts/install-run-rush.js update --full --recheck | |
| # Initializes the CodeQL tools for scanning | |
| - name: Initialize CodeQL | |
| uses: github/codeql-action/init@v3 | |
| with: | |
| languages: ${{ matrix.language }} | |
| config-file: ./.github/codeql/codeql-config.yml | |
| # Build JavaScript project specifically (skipping autobuild for JavaScript) | |
| - name: Build JavaScript | |
| # Only run the build for Typescript/JavaScript language match | |
| if: matrix.language == 'javascript-typescript' | |
| run: npm run build | |
| # Perform the CodeQL Analysis | |
| - name: Perform CodeQL Analysis | |
| uses: github/codeql-action/analyze@v3 | |
| with: | |
| category: "/language:${{matrix.language}}" | |
| upload-database: false | |
| # Debug CodeQL configuration | |
| - name: Debug CodeQL configuration | |
| if: always() | |
| run: | | |
| echo "Executed CodeQL for language: ${{ matrix.language }}" | |
| echo "Category used: /language:${{ matrix.language }}" | |
| echo "Node version: ${{ matrix.node-version || 'N/A' }}" |