packages updated, due to security warning in cryptography. Upgrade to… #63
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
| name: Tests-and-Linters | |
| permissions: | |
| contents: read | |
| on: | |
| pull_request: | |
| branches: | |
| - master | |
| jobs: | |
| check-branch-name: | |
| name: Check git branch name | |
| runs-on: ubuntu-slim | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v4 | |
| with: | |
| ref: ${{ github.head_ref }} | |
| - name: Make script executable | |
| run: chmod +x .linters/check_git_branch_name.sh | |
| - name: Run branch name check | |
| run: .linters/check_git_branch_name.sh | |
| test: | |
| needs: check-branch-name | |
| runs-on: ubuntu-slim | |
| strategy: | |
| fail-fast: false | |
| matrix: | |
| python-version: ["3.10", "3.11", "3.12", "3.13", "3.14"] | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - name: Set up Python ${{ matrix.python-version }} | |
| uses: actions/setup-python@v4 | |
| with: | |
| python-version: ${{ matrix.python-version }} | |
| - name: Install uv | |
| uses: astral-sh/setup-uv@681c641aba71e4a1c380be3ab5e12ad51f415867 | |
| - name: Create virtual environment | |
| run: uv venv | |
| - name: Restore cache uv | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/.cache/uv | |
| .venv | |
| key: uv-${{ runner.os }}-${{ matrix.python-version }}-${{ hashFiles('**/pyproject.toml') }} | |
| restore-keys: | | |
| uv-${{ runner.os }}-${{ matrix.python-version }}- | |
| - name: Install dependencies | |
| run: | | |
| uv sync --dev | |
| - name: Create CAI config and tokens | |
| run: | | |
| mkdir -p /home/runner/.config/cai /home/runner/work/.config/cai | |
| cp .github/ci/cai_config.ci.yml /home/runner/.config/cai/cai_config.yml | |
| cp .github/ci/cai_config.ci.yml /home/runner/work/.config/cai/cai_config.yml | |
| cp .github/ci/tokens.ci.yml /home/runner/.config/cai/tokens.yml | |
| cp .github/ci/tokens.ci.yml /home/runner/work/.config/cai/tokens.yml | |
| - name: Run tests | |
| run: | | |
| uv run pytest | |
| megalinter: | |
| name: MegaLinter | |
| needs: test | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: write | |
| issues: write | |
| pull-requests: write | |
| steps: | |
| # Git Checkout | |
| - name: Checkout Code | |
| uses: actions/checkout@v6 | |
| with: | |
| token: ${{ secrets.PAT || secrets.GITHUB_TOKEN }} | |
| fetch-depth: 0 | |
| - name: Generate version file | |
| run: cp .github/ci/_version.py "$GITHUB_WORKSPACE/src/git_cai_cli/_version.py" | |
| # MegaLinter | |
| - name: MegaLinter | |
| uses: oxsecurity/megalinter@42bb470545e359597e7f12156947c436e4e3fb9a | |
| id: ml | |
| env: | |
| VALIDATE_ALL_CODEBASE: false | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| # Upload MegaLinter artifacts | |
| - name: Archive production artifacts | |
| if: success() || failure() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: MegaLinter reports | |
| include-hidden-files: "true" | |
| path: | | |
| megalinter-reports | |
| mega-linter.log |