diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index a0ae641..741055e 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -1,32 +1,30 @@ name: CI -on: [push, pull_request] +on: + push: + branches: + - main + pull_request: + +permissions: + contents: read jobs: build: name: Build runs-on: ubuntu-latest steps: + - name: Checkout repository + uses: actions/checkout@v4 - name: Set up Go 1.x - uses: actions/setup-go@v2 + uses: actions/setup-go@v5 with: go-version: ^1.13 id: go - - name: Checkout repository - uses: actions/checkout@v2 - - - name: Set up cache - uses: actions/cache@v2 - with: - path: ~/go/pkg/mod - key: ${{ runner.os }}-go-${{ hashFiles('**/go.sum') }} - restore-keys: | - ${{ runner.os }}-go- - - name: Get dependencies run: go get -v -t -d . - name: Build go - run: go build \ No newline at end of file + run: go build