-
Notifications
You must be signed in to change notification settings - Fork 10
Fix: version passing to GoReleaser configuration #115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Coverage summary from CodacySee diff coverage on Codacy
Coverage variation details
Coverage variation is the difference between the coverage for the head and common ancestor commits of the pull request branch: Diff coverage details
Diff coverage is the percentage of lines that are covered by tests out of the coverable lines that the pull request added or modified: See your quality gate settings Change summary preferences |
- Change Go version retrieval method in .goreleaser.yaml to use GOVERSION from environment variables. - Add a step in GitHub Actions workflow to extract and set the Go version for use in the release process.
- Change GoReleaser version from 'latest' to '~> v1' in GitHub Actions workflow to ensure compatibility with specific version range.
| distribution: goreleaser | ||
| # 'latest', 'nightly', or a semver | ||
| version: "latest" | ||
| version: "~> v1" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
his change to version: "~> v1" means:
You'll always get the latest v1.x.x release
You're protected from breaking changes that might come in v2.0.0
You'll automatically get bug fixes and minor improvements within the v1 series
It's more flexible than pinning to a specific version while still maintaining stability
This is what the warning was suggesting as a best practice, and it's a better approach than either using latest (too loose) or a specific version like v1.21.1 (too strict).
Revert some changes made with #115
fix: version passing to GoReleaser configuration
Fix version command by properly configuring GoReleaser and version injection:
This ensures the version command shows correct build information
and follows GoReleaser's best practices for version constraints.