This adds a semver package to handle the version management.
This is a refactor to lay the foundation for #153 where we will need to validate patch versions
Note: I looked into the go semver package but it surprisingly does not handle patches very well. But in the "go" way I just wrote some functions to handle versions the way we need to.
Since most of the pkg/utils package was mostly for versioning, I also moved the rest of that package into new or exiting packages:
utils/utils.go#{version handling functions} -> pkg/semver : cleaner interface for dealing with versions
utils/utils.go#NextReleaseDate -> cmd/render/utils : It's only used in the render checklist command
utils/yq* -> pkg/yq : Cleaner as its own package
pkg/utils/change_logs.go -> pkg/release/utils.go : These are all release related
This adds a
semver
package to handle the version management. This is a refactor to lay the foundation for #153 where we will need to validate patch versionsNote: I looked into the go semver package but it surprisingly does not handle patches very well. But in the "go" way I just wrote some functions to handle versions the way we need to.
Since most of the
pkg/utils
package was mostly for versioning, I also moved the rest of that package into new or exiting packages:utils/utils.go#{version handling functions}
->pkg/semver
: cleaner interface for dealing with versionsutils/utils.go#NextReleaseDate
->cmd/render/utils
: It's only used in the render checklist commandutils/yq*
->pkg/yq
: Cleaner as its own packagepkg/utils/change_logs.go
->pkg/release/utils.go
: These are all release related