Skip to content
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

feat(v2): add GoVersion package variable #283

Merged
merged 2 commits into from
Jun 8, 2023

Conversation

noahdietz
Copy link
Contributor

@noahdietz noahdietz commented Jun 5, 2023

Adds GoVersion package variable that is populated on init with an internal goVersion method. This goVersion method is a copy of the versionGo method, which was generated in every GAPIC. Once this is released, we can remove versionGo from every GAPIC while migrating all to use this GoVersion (googleapis/gapic-generator-go#1299)

Note: The goVersion implementation was copied directly from the generated versionGo except for one caveat. When the runtime version is a prerelease and already contains a dash - separator, we don't need to include another one when concatenating the semver and prerelease strings.

@noahdietz noahdietz requested a review from codyoss June 5, 2023 21:10
@noahdietz noahdietz requested a review from a team as a code owner June 5, 2023 21:10
@noahdietz noahdietz requested a review from quartzmo June 6, 2023 20:28
v2/header.go Outdated Show resolved Hide resolved
v2/header.go Outdated Show resolved Hide resolved
@noahdietz noahdietz requested a review from codyoss June 7, 2023 19:57
@noahdietz noahdietz changed the title feat(v2): add GoVersion helper feat(v2): add GoVersion package variable Jun 7, 2023
@noahdietz noahdietz merged commit 26553cc into googleapis:main Jun 8, 2023
4 checks passed
@noahdietz noahdietz deleted the go-version branch June 8, 2023 16:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants