diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6ab75cc..1b4002a 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -16,8 +16,13 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-go@v5 with: - go-version: "1.25" - - run: go test ./... -v -race + go-version-file: go.mod + - run: go test ./... -v -race -coverprofile=coverage.out + - name: Upload coverage to Codecov + if: matrix.os == 'ubuntu-latest' + uses: codecov/codecov-action@v5 + with: + files: coverage.out - run: go vet ./... build: @@ -29,5 +34,5 @@ jobs: - uses: actions/checkout@v4 - uses: actions/setup-go@v5 with: - go-version: "1.25" + go-version-file: go.mod - run: go build . diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index 4499bb2..2a00478 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -17,7 +17,7 @@ jobs: fetch-depth: 0 - uses: actions/setup-go@v5 with: - go-version: "1.25" + go-version-file: go.mod - uses: goreleaser/goreleaser-action@v6 with: version: "~> v2" diff --git a/README.md b/README.md index 27b24d1..9dc257e 100644 --- a/README.md +++ b/README.md @@ -4,6 +4,7 @@ [![Go Reference](https://pkg.go.dev/badge/github.com/tirthpatell/mdr.svg)](https://pkg.go.dev/github.com/tirthpatell/mdr) [![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://opensource.org/licenses/MIT) [![Release](https://img.shields.io/github/v/release/tirthpatell/mdr)](https://github.com/tirthpatell/mdr/releases) +[![codecov](https://codecov.io/gh/tirthpatell/mdr/branch/main/graph/badge.svg)](https://codecov.io/gh/tirthpatell/mdr) Markdown renderer, editor, and linter for the terminal.