* Emmit warning and change behavior based on ASDF_GOLANG_MOD_VERSION
* Add note on ASDF_GOLANG_MOD_VERSION to README.
* Rename to ASDF_GOLANG_MOD_VERSION_ENABLED.
* Add ASDF_GOLANG_OVERWRITE_ARCH override option
This change adds an ASDF_GOLANG_OVERWRITE_ARCH variable to allow overriding the architecture. This is useful if you need to install version of Go that were not released for macOS ARM. This is also done in the asdf terraform plugin: e1c7eea0f7/bin/install (L115-L129)
* Update README to include section about ASDF_GOLANG_OVERWRITE_ARCH
The go directive in go.mod files is of the format `major.minor`. This
commit will allow the highest installed version of go with the same
major component to be selected. The previous behaviour was to use the
highest installed version with the same major _and_ minor components,
but I don't think this was strictly necessary. It is valid to use go
1.16 to build a project whose go.mod declares "go 1.14", for example.
For packages within the module, the compiler should reject use of
language features introduced after the version specified by the go
directive.
I think this adheres more closely to the expected behaviour of programs
that parse `go.mod`, and asdf users who need to pin a particular minor
or patch version of go can use `.tool-versions` or `.go-version`.
Source: https://golang.org/ref/mod#go-mod-file-go