Closed yonahd closed 11 months ago
Can i work on it ? and can you point me in some direction? Thank you
Can i work on it ? and can you point me in some direction? Thank you
Sure.
Take a look at https://github.com/yonahd/kor/blob/main/pkg/utils/banner.go And https://github.com/yonahd/kor/blob/main/cmd/kor/root.go#L48
Hey, i just wanted to ask where can i get the current version number of kor running @yonahd
This comes from the git tag. It would need to be embedded during build time possibly in the goreleaser https://www.reddit.com/r/golang/comments/udhml7/best_way_to_embed_version_info_into_binary/?rdt=40697
Sorry, it is taking me some time, as i have some tests coming up in my class. I will try my best to fix the issue, i need some time
No rush
@yonahd
I plan to update the .goreleaser.yml
to add
builds:
- id: OS
ldflags:
- -X github.com/yonahd/kor/pkg/utils.version={{.Version}}
snapshot:
name_template: "{{ .Version }}"
that way I guess I can access the version from the git tag Does this look good?
I wanted to ask where should I print the version and the format of it ?
@yonahd I plan to update the
.goreleaser.yml
to addbuilds: - id: OS ldflags: - -X github.com/yonahd/kor/pkg/utils.version={{.Version}} snapshot: name_template: "{{ .Version }}"
that way I guess I can access the version from the git tag Does this look good?
I wanted to ask where should I print the version and the format of it ?
I would need to test this. I want to add it in the utils just like the printing of the kor banner
is this formatting okay ?
Perfect
Is your feature request related to a problem? Please describe. When running in cluster we should be able to clearly see the version of kor on startup
Describe the solution you'd like Print the version on startup e.g.
v0.2.7