From fd0cfb6a969c306bfaa48d3025bf15803ab7b08f Mon Sep 17 00:00:00 2001 From: Nicolas Bock Date: Fri, 25 Aug 2023 12:17:53 -0600 Subject: [PATCH] Unify PR and main workflows Signed-off-by: Nicolas Bock --- .github/workflows/pr-checks.yml | 21 ------------------- .../{main-branch.yml => test-and-build.yaml} | 11 ++++++---- 2 files changed, 7 insertions(+), 25 deletions(-) delete mode 100644 .github/workflows/pr-checks.yml rename .github/workflows/{main-branch.yml => test-and-build.yaml} (71%) diff --git a/.github/workflows/pr-checks.yml b/.github/workflows/pr-checks.yml deleted file mode 100644 index 29d2005..0000000 --- a/.github/workflows/pr-checks.yml +++ /dev/null @@ -1,21 +0,0 @@ -on: - pull_request: - branches: - - main -name: Tests for pull requests -jobs: - test: - strategy: - matrix: - go-version: [1.16.x] - os: [ubuntu-latest] - runs-on: ${{ matrix.os }} - steps: - - name: Install Go - uses: actions/setup-go@v2 - with: - go-version: ${{ matrix.go-version }} - - name: Checkout code - uses: actions/checkout@v2 - - name: Test and Build - run: make all diff --git a/.github/workflows/main-branch.yml b/.github/workflows/test-and-build.yaml similarity index 71% rename from .github/workflows/main-branch.yml rename to .github/workflows/test-and-build.yaml index 7e7e2d3..8e9dcb6 100644 --- a/.github/workflows/main-branch.yml +++ b/.github/workflows/test-and-build.yaml @@ -2,21 +2,24 @@ on: push: branches: - main + pull_request: + branches: + - main + name: Tests/Jobs for main branch merges jobs: test: strategy: matrix: - go-version: [ 1.16.x ] + go-version: [ 1.16 ] os: [ ubuntu-latest ] runs-on: ${{ matrix.os }} steps: - name: Install Go - uses: actions/setup-go@v2 + uses: actions/setup-go@v4 with: go-version: ${{ matrix.go-version }} - name: Checkout code - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Test and Build run: make all -