Skip to content

Conversation

@juanrgon
Copy link

@juanrgon juanrgon commented Aug 30, 2025

Problem

Was running into this error when trying to install go 1.25:

> asdf install golang 1.25
Invalid version format: '1.25'. Go versions must be in the format 'major.minor.patch' (e.g., '1.25.0').

Took me a while to realize that the issue is that the version has to be in MAJOR.MINOR.PATCH format, e.g.

this

asdf install golang 1.25

not this

asdf install golang 1.25.0

Fix

This pull request introduces a new utility function to validate version strings in the lib/helpers.sh script. The main change is the addition of a function that ensures version numbers conform to the expected major.minor.patch format.


Note

Add version format validator (MAJOR.MINOR.PATCH) and invoke it in the Go download path.

  • Validation:
    • Add validate_version in lib/helpers.sh to enforce major.minor.patch (e.g., 1.25.0).
  • Download flow:
    • Call validate_version in bin/download's download_golang before building the download URL.

Written by Cursor Bugbot for commit a428e18. This will update automatically on new commits. Configure here.

@juanrgon juanrgon requested a review from a team as a code owner August 30, 2025 18:39
@smorimoto
Copy link
Member

bugbot run

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Bugbot reviewed your changes and found no bugs!


Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants