From 2825449c7f6865287b7391b6c6dea62e811f5bfc Mon Sep 17 00:00:00 2001 From: Casey Lee Date: Sun, 28 Mar 2021 22:15:56 -0700 Subject: [PATCH] add codecov integration (#585) * add codecov integration * include past tags when releasing --- .github/workflows/push.yml | 10 ++++++++-- .gitignore | 2 ++ 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/.github/workflows/push.yml b/.github/workflows/push.yml index b18f48d..51bf692 100644 --- a/.github/workflows/push.yml +++ b/.github/workflows/push.yml @@ -23,9 +23,13 @@ jobs: - uses: actions/setup-go@v1 with: go-version: 1.14 - - run: go test -cover ./... + - run: go test -cover -coverprofile=coverage.txt -covermode=atomic ./... env: - CGO_ENABLED: 0 + CGO_ENABLED: 0 + - uses: codecov/codecov-action@v1 + with: + files: coverage.txt + fail_ci_if_error: true # optional (default = false) snapshot: name: Snapshot @@ -66,6 +70,8 @@ jobs: runs-on: ubuntu-latest steps: - uses: actions/checkout@v2 + with: + fetch-depth: 0 - name: GoReleaser uses: goreleaser/goreleaser-action@v1 with: diff --git a/.gitignore b/.gitignore index 4e8e199..b7bf04a 100644 --- a/.gitignore +++ b/.gitignore @@ -17,3 +17,5 @@ *.nupkg .vscode/ .idea/ + +coverage.txt