diff --git a/.github/workflows/project-checks.yaml b/.github/workflows/project-checks.yaml deleted file mode 100644 index 14e57c4b4..000000000 --- a/.github/workflows/project-checks.yaml +++ /dev/null @@ -1,67 +0,0 @@ -name: Project Checks - -on: - push: - branches: - - main - - "release-*" - - "test/**" - pull_request: - branches: - - main - - "release-*" - -env: - GO_VERSION: "1.22.1" - -jobs: - verify: - name: Minimal PR Verification - runs-on: ubuntu-22.04 - timeout-minutes: 5 - steps: - - name: Check out repository - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - - name: Install golang toolchain - uses: actions/setup-go@v5 - with: - go-version: ${{ env.GO_VERSION }} - - - name: Check PR for whitespace errors - if: ${{ github.event_name == 'pull_request' }} - run: | - if ! git diff-index --check origin/${{ github.base_ref }} --; then - echo "This PR would introduce the errors shown above." - echo "Please fix them and update the PR." - exit 1 - fi - - - name: Verify dependencies - run: | - make verify-godeps - - - name: Verify formatting - run: | - make verify-fmt - - - name: Verify generated assets - run: | - make verify-generate - - - name: Verify binary builds - run: | - make verify-build - - - name: Install gh-pages build dependencies - run: | - pip3 install --user -r docs/requirements.txt - echo "`python3 -m site --user-base`/bin" >> $GITHUB_PATH - - - name: Verify documentation / update of gh-pages - run: | - git config user.name "Github" - git config user.email "no-reply@github.com" - ./scripts/build/update-gh-pages.sh diff --git a/.github/workflows/verify.yaml b/.github/workflows/verify.yaml new file mode 100644 index 000000000..d5d79bb45 --- /dev/null +++ b/.github/workflows/verify.yaml @@ -0,0 +1,92 @@ +name: Verify + +on: + push: + branches: + - main + - "release-*" + - "test/**" + pull_request: + branches: + - main + - "release-*" + +env: + GO_VERSION: "1.22.1" + +jobs: + verify-deps: + name: Dependencies + runs-on: ubuntu-24.04 + timeout-minutes: 5 + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-go@v5 + with: + go-version: ${{ env.GO_VERSION }} + - run: | + make verify-godeps + + verify-formatting: + name: Formatting + runs-on: ubuntu-24.04 + timeout-minutes: 5 + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-go@v5 + with: + go-version: ${{ env.GO_VERSION }} + - run: | + if ! git diff-index --check origin/${{ github.base_ref }} --; then + echo "This PR would introduce the errors shown above." + echo "Please fix them and update the PR." + exit 1 + fi + if: ${{ github.event_name == 'pull_request' }} + - run: | + make verify-fmt + + verify-generated: + name: Generated Assets + runs-on: ubuntu-24.04 + timeout-minutes: 5 + steps: + - uses: actions/checkout@v4 + - uses: actions/setup-go@v5 + with: + go-version: ${{ env.GO_VERSION }} + - run: | + make verify-generate + + verify-build: + name: Builds + runs-on: ubuntu-24.04 + timeout-minutes: 5 + steps: + - uses: actions/checkout@v4 + with: + feth-depth: 0 + - uses: actions/setup-go@v5 + with: + go-version: ${{ env.GO_VERSION }} + - run: | + make verify-build + + verify-docs: + name: Documentation + runs-on: ubuntu-24.04 + timeout-minutes: 5 + steps: + - uses: actions/checkout@v4 + with: + feth-depth: 0 + - uses: actions/setup-go@v5 + with: + go-version: ${{ env.GO_VERSION }} + - run: | + pip3 install --user -r docs/requirements.txt + echo "`python3 -m site --user-base`/bin" >> $GITHUB_PATH + - run: | + git config user.name "Github" + git config user.email "no-reply@github.com" + ./scripts/build/update-gh-pages.sh