This repository was archived by the owner on Sep 10, 2025. It is now read-only.
Update runner type to macos-14 in workflow #2776
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
| # GitHub Actions CodeQL Workflow | |
| name: CodeQL | |
| on: | |
| pull_request: | |
| branches: [main] | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v2 | |
| - name: Initialize CodeQL | |
| uses: github/codeql-action/init@v1 | |
| with: | |
| languages: python, cpp | |
| - name: Install Ninja | |
| run: | | |
| sudo apt-get update -y | |
| sudo apt-get install -y ninja-build | |
| - name: Update submodules | |
| run: git submodule update --init --recursive | |
| - name: Install Torch | |
| run: | | |
| python -m pip install cmake | |
| sudo ln -s /usr/bin/ninja /usr/bin/ninja-build | |
| - name: Build TorchText | |
| run: | | |
| python -m pip install setuptools==65.7.0 | |
| python setup.py develop --user | |
| # If any code scanning alerts are found, they will be under Security -> CodeQL | |
| # Link: https://github.com/pytorch/text/security/code-scanning | |
| - name: Perform CodeQL Analysis | |
| uses: github/codeql-action/analyze@v1 |