-
Notifications
You must be signed in to change notification settings - Fork 26
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
go version should inform that the go binary is generated by microsoft #262
Comments
I think we should probably still use a tool to do this, because upstream commits a I actually already put in a way for the Docker infra to detect when we have a We should ideally set up our upstream sync tool to reset
👍 The approach I looked at in #140 (comment) where I tried modifying the linker itself was way overcomplicated. It's also nice to not even need to modify |
I noticed something weird about go1.18beta2: the tag https://github.com/golang/go/tree/go1.18beta2 has no It turns out Go's release tooling adds the This seems to me to reinforce that this is the right thing for us to do, too. |
Reference: microsoft/go#262 Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com>
Reference: microsoft/go#262 Signed-off-by: Muhammad Falak R Wani <falakreyaz@gmail.com>
The
go version
is used to know which is the version ofgo
binary being used and it can also discover whichgo
version was used to generated a binary. This version is taken from aVERSION
file in the root dir, and if it does not exist it is generated on the fly following this logic: https://github.com/golang/go/blob/577287728a8e8abbcbc6c96fdd49feb5a99ced0c/src/cmd/dist/build.go#L348For example, running
go version
on my computers it outputsgo version devel go1.18-505a7c80f2 Wed Nov 3 18:06:56 2021 -0500 windows/amd64
.We should include Microsoft-specific information in that output, such as the
microsoft
tag and probably a AzDO build number (when doing intermediate releases).I propose to do it as follows:
microsoft/main
does not have any committedVERSION
file.VERSION
file does not exist. This auto-generated file will contain at least amicrosoft
tag and the AzDO build number.VERSION
file on every release branch with at least themicrosoft
tag and the released version number.boringcrypto
andopenssl
branches will have a special tag that clearly identifies themThis approach has the nice property that no upstream code has to be modified as all the logic will be put on
microsoft/go-infra
.(Forked from #140)
The text was updated successfully, but these errors were encountered: