Skip to content

fix: split documents (#120) #21

fix: split documents (#120)

fix: split documents (#120) #21

Workflow file for this run

# Reference from:
# https://goreleaser.com/ci/actions/
name: Release
on:
push:
tags:
- "v*"
permissions:
contents: write
jobs:
Test:
name: Unit tests with coverage
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version-file: 'go.mod'
- run: go version
- run: go env
- run: go test ./...
- run: go build
- name: Running go tests with coverage
env:
GO111MODULE: on
run: make cover
- name: Send coverage
uses: shogo82148/actions-goveralls@v1
with:
path-to-profile: coverage.out
Publish: # Pack and publish image to Docker Hub and Github Release
runs-on: ubuntu-latest
needs: [Test]
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
with:
go-version: 1.18
# <--- Login, build and push image to Docker Hub --->
- name: Login to Docker Hub
uses: docker/login-action@v3
with:
username: ${{ secrets.DOCKER_USERNAME }}
password: ${{ secrets.DOCKER_PASSWORD }}
# <--- End --->
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v6
with:
distribution: goreleaser
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}