Hi guys. I’m new to Go. I’ve installed it on my Windows 10 computer. I also installed MYSYS2 and Fyne. I’ve added the paths for both Go and MYSYS2 to my environment variables. When I try to run the command on the getting started page, my command line just hangs. (See the screenshot: GO-FYNE-ERROR — ImgBB) Any idea what I can try next? I’m just trying to see if I can get the demo app for Fyne to run before I try any actual coding. Thanks in advance for the help.
PS - FYI: Can we get the example on the getting started guide updated for ‘go install’ instead of ‘go get’? I had to troubleshoot that. Also had to manually add the path for GCC from the MYSYS2 directory in C:/mysys64. It might help to add a note about that to the example for users with MYSYS2.
I’m a total noob to Go - so its possible I’m just dorking stuff up.
Hi @Landon_Blake, welcome to Go and to the forum!
The error message advises to add @latest to the end of the
go install command:
go install some/import/path@latest
That advice might look rather cryptic, so here is some background.
Go has a module system since Go 1.11 (and officially since Go 1.13). Before that, Go had a single-workspace model that was super easy to understand but often cumbersome to deal with.
With the introduction of the module system, some commands have changed slightly. Moreover, some commands work in a different way when they are inside a module-aware project versus being outside of such a project.
You can see if a Go project is module-aware by looking for a
go.mod file in the project’s root directory.
Now when you call
go install outside a module-aware project, the command requires to add version information to the repo path you want to install from.
You can specify an existing version (determined by a Git tag) like
@v.1.2.3, or simply use
@latest to get the newest and freshest version.
This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.