Merge pull request #165 from hindermath/codex/046-gsdb-spec-kit-inten… #928
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: Homogeneity Check | |
| on: | |
| push: | |
| pull_request: | |
| jobs: | |
| check: | |
| name: Repository Tooling (${{ matrix.os }}) | |
| runs-on: ${{ matrix.os }} | |
| timeout-minutes: 10 | |
| strategy: | |
| matrix: | |
| os: [ubuntu-22.04, macos-14, windows-2022] | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@9c091bb21b7c1c1d1991bb908d89e4e9dddfe3e0 # v7.0.0 | |
| with: | |
| fetch-depth: 0 | |
| - name: Install ripgrep (Ubuntu) | |
| if: runner.os == 'Linux' | |
| run: | | |
| sudo apt-get update | |
| sudo apt-get install -y ripgrep | |
| - name: Install ripgrep (macOS) | |
| if: runner.os == 'macOS' | |
| run: brew install ripgrep | |
| - name: Install pinned ripgrep (Windows) | |
| if: runner.os == 'Windows' | |
| shell: pwsh | |
| run: | | |
| $version = '15.2.0' | |
| $archive = "ripgrep-${version}-x86_64-pc-windows-msvc.zip" | |
| $release = "https://github.com/BurntSushi/ripgrep/releases/download/${version}" | |
| $archivePath = Join-Path $env:RUNNER_TEMP $archive | |
| $checksumPath = "${archivePath}.sha256" | |
| $extractRoot = Join-Path $env:RUNNER_TEMP 'ripgrep' | |
| Invoke-WebRequest -Uri "${release}/${archive}" -OutFile $archivePath | |
| Invoke-WebRequest -Uri "${release}/${archive}.sha256" -OutFile $checksumPath | |
| $expected = Get-Content -LiteralPath $checksumPath | | |
| Where-Object { $_ -match '^[0-9a-fA-F]{64}$' } | | |
| Select-Object -First 1 | |
| if ([string]::IsNullOrWhiteSpace($expected)) { | |
| throw 'The published ripgrep checksum file contains no SHA-256 hash.' | |
| } | |
| $expected = $expected.ToLowerInvariant() | |
| $actual = (Get-FileHash -LiteralPath $archivePath -Algorithm SHA256).Hash.ToLowerInvariant() | |
| if ($actual -ne $expected) { | |
| throw "ripgrep checksum mismatch: expected ${expected}, received ${actual}." | |
| } | |
| Expand-Archive -LiteralPath $archivePath -DestinationPath $extractRoot -Force | |
| $binPath = Join-Path $extractRoot "ripgrep-${version}-x86_64-pc-windows-msvc" | |
| $binPath | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append | |
| $env:PATH = "${binPath};${env:PATH}" | |
| rg --version | |
| - name: Run Agent Secret Scan (Bash) | |
| if: runner.os != 'Windows' | |
| run: bash scripts/scan-agent-secrets.sh --fail-on-high . | |
| - name: Run Agent Secret Scan (Bash on Windows) | |
| if: runner.os == 'Windows' | |
| shell: bash | |
| run: bash scripts/scan-agent-secrets.sh --fail-on-high . | |
| - name: Run Homogeneity Check (Bash) | |
| if: runner.os != 'Windows' | |
| run: bash scripts/check-homogeneity.sh --dry-run --no-patch "$GITHUB_WORKSPACE" | |
| - name: Run Homogeneity Check (PowerShell) | |
| if: runner.os == 'Windows' | |
| shell: pwsh | |
| run: pwsh -NoProfile -File scripts/check-homogeneity.ps1 -TargetDir $env:GITHUB_WORKSPACE -DryRun -NoPatch | |
| - name: Run Lastenheft Rename Contract | |
| shell: bash | |
| run: bash tests/scripts/rename-lastenheft-tests.sh |