Skip to content

Commit

Permalink
Merge pull request #15408 from smowton/smowton/admin/log-setup-go-mes…
Browse files Browse the repository at this point in the history
…sage

Log advice when a newer Go version is required under Actions
  • Loading branch information
smowton authored Jan 23, 2024
2 parents d29d060 + 7e96eaa commit 43453fe
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions go/extractor/cli/go-autobuilder/go-autobuilder.go
Original file line number Diff line number Diff line change
Expand Up @@ -800,6 +800,9 @@ func installDependenciesAndBuild() {
// Go tooling should install required Go versions as needed.
if semver.Compare(getEnvGoSemVer(), "v1.21.0") < 0 && goVersionInfo.Found && semver.Compare("v"+goVersionInfo.Version, getEnvGoSemVer()) > 0 {
diagnostics.EmitNewerGoVersionNeeded()
if val, _ := os.LookupEnv("GITHUB_ACTIONS"); val == "true" {
log.Printf("The go.mod version is newer than the installed version of Go. Consider adding an actions/setup-go step to your workflow.\n")
}
}

fixGoVendorIssues(&buildInfo, goVersionInfo.Found)
Expand Down

0 comments on commit 43453fe

Please sign in to comment.