-
Notifications
You must be signed in to change notification settings - Fork 63
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
fix: version command fix #149
Conversation
Signed-off-by: James-Milligan <james@omnant.co.uk>
Does the |
it does not, example output:
|
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.
This seems to be slightly confusing, if its not "devel" version it will use the vcs.time value from the build info? What about the params in main?
The version key value from As for the remaining values ( |
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.
This isn't working as expected when producing a docker image
❯ docker run cnskunkworks/flagd:james-branch version
______ __ ________ _______ ______
/_____/\ /_/\ /_______/\ /______/\ /_____/\
\::::_\/_\:\ \ \::: _ \ \\::::__\/__\:::_ \ \
\:\/___/\\:\ \ \::(_) \ \\:\ /____/\\:\ \ \ \
\:::._\/ \:\ \____\:: __ \ \\:\\_ _\/ \:\ \ \ \
\:\ \ \:\/___/\\:.\ \ \ \\:\_\ \ \ \:\/.:| |
\_\/ \_____\/ \__\/\__\/ \_____\/ \____/_/
flagd (5365272) built at 2022-08-22T15:59:00Z
The injected arg is --build-arg=VERSION="$$(git describe --tags --abbrev=0)"
which provides the tag locally on your repo of v0.0.1
which I created manually.
just looked into this and it seems the version value remains unset in this example, which is making me lose confidence in this as an approach, a simple fix would be to replace: |
Perhaps unless it's a downloaded release we compromise to say that go install will be
if someone wants a supported version they download a release? |
Signed-off-by: James-Milligan <james@omnant.co.uk>
Personally I would feel more comfortable with a 'hacky' approach than to not provide a version at all on the What are your thoughts @skyerus @beeme1mr @toddbaert |
I don't have a problem with the revised code now, this wasn't the case when we discussed it previously, so I am happy to accept it now... |
Possible fix for populating version variables when using
go install
Signed-off-by: James-Milligan james@omnant.co.uk