asdf-community / asdf-golang

Go plugin for the asdf version manager
https://github.com/asdf-vm/asdf
MIT License
534 stars 88 forks source link

Would it be possible to set ASDF_GOLANG_MOD_VERSION_ENABLED in ~/.asdfrc? #119

Open skhaz opened 1 year ago

skhaz commented 1 year ago

The Node plugin has a property called legacy_version_file, which can be set to true at the user's discretion. I have nothing against environment variables, but ASDF already has a configuration file, and I believe that this flag, which is important by the way, should go in ~/.asdfrc.

Certainly, it doesn't need to be all uppercase; it could be golang_mod_version_enabled.

What do you think?

ankitcharolia commented 1 year ago

@skhaz Kindly try out this goenv: https://github.com/ankitcharolia/goenv

skhaz commented 1 year ago

@ankitcharolia, don’t get me wrong, I want to use asdf, I use it for several things. If I needed to use a separate tool for managing go versions, I went back to brew.

dennisvandehoef commented 1 year ago

The Node plugin has a property called legacy_version_file

Actually, the ruby plugin also uses the exact same config option to read the .ruby-version file. So we could even argue to listen to that config option instead of adding a new one.

Heaving that sad, I am fine with both solutions, as long as I can configure ASDF from the config file instead of a variable which lays somewhere else.