Bump github.com/gin-contrib/cors from 1.7.2 to 1.7.3 #386
This file contains 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: build | |
on: | |
push: | |
branches: | |
- main | |
pull_request: | |
types: | |
- opened | |
- reopened | |
- synchronize | |
jobs: | |
tests: | |
runs-on: ubuntu-latest | |
name: 'Unit Tests' | |
steps: | |
- name: 'Checkout Repo' | |
uses: actions/checkout@v4 | |
- name: 'Setup Go' | |
uses: actions/setup-go@v4 | |
with: | |
go-version: ^1.22 | |
- name: 'Setup Node' | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
- name: 'Build Frontend Artefacts' | |
run: yarn && NODE_OPTIONS=--openssl-legacy-provider yarn build | |
- name: 'Run Tests' | |
run: go test -cover -coverprofile=coverage.txt ./... | |
- name: 'Archive Coverage Results' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: code-coverage | |
path: coverage.txt | |
code_coverage: | |
name: 'Code Coverage Report' | |
if: github.event_name == 'pull_request' | |
runs-on: ubuntu-latest | |
needs: tests | |
steps: | |
- uses: fgrosse/go-coverage-report@v1.0.0 | |
with: | |
coverage-artifact-name: 'code-coverage' | |
coverage-file-name: 'coverage.txt' | |
build_and_artefact: | |
strategy: | |
matrix: | |
os: ['linux', 'darwin', 'windows'] | |
arch: ['amd64'] | |
name: 'Build and Artefact' | |
runs-on: ubuntu-latest | |
needs: tests | |
steps: | |
- name: 'Checkout Repo' | |
uses: actions/checkout@v4 | |
- name: 'Setup Go' | |
uses: actions/setup-go@v4 | |
with: | |
go-version: ^1.22 | |
- name: 'Setup Node' | |
uses: actions/setup-node@v4 | |
with: | |
node-version: 20 | |
- name: 'Build Frontend Artefacts' | |
run: yarn && NODE_OPTIONS=--openssl-legacy-provider yarn build | |
- name: 'Matrix Binary Compilation' | |
run: GOOS=${{ matrix.os }} GOARCH=${{ matrix.arch }} go build -o dist/roadie.${{ matrix.arch }}-${{ matrix.os }} ./cmd/roadie | |
- name: 'Archive Binary' | |
uses: actions/upload-artifact@v4 | |
with: | |
name: binary-${{ matrix.arch }}-${{ matrix.os }} | |
path: dist/roadie.${{ matrix.arch }}-${{ matrix.os }} | |