Open c1tt1 opened 6 years ago
From what i understand in the near future joy will simply reside in the GOPATH along with its dependencies.
So you can delete it from there like any other go program / package.
The script says it installs itself here: /usr/local/bin/joy
And by the way do you mean GOROOT?
yes what you say is true thats the place where it gets installed when you use the install script.
when you install it like this (which is the default go way):
go get github.com/matthewmueller/joy/cmd/joy
It gets installed into the GOPATH which is the place where go packages are installed
GOPATH/src for sourcecode GOPATH/pkg for libraries GOPATH/bin for executables likes for example the joy compiler
GOROOT is where the language go itself is installed
If you didn't define a GOPATH yourselves from go 1.8 on it is being set to the $HOME/go
on UNIX systems and %USERPROFILE%/go
on windows.
thanks closing
Will reopen because there will need to be some state elsewhere. I've tried just keeping all the state inside $GOPATH/src/matthewmueller/joy
, but it messes with trying to go get
on top of the existing files.
I agree with this and will accept a PR to make this easier. Let me just finalize the location of this extra state before this work gets started.
I've been toying with either having this extra state in $GOPATH/src/matthewmueller/.joy
, though right now it's where your OS stores it's preferences. I think I've fixed the bugs around loading outside of $GOPATH, so I think either spot will be fine. It's safe to delete this folder as it will be regenerated the next time you run joy.
More information here: https://github.com/matthewmueller/joy/blob/4e548d86c69a79623679ac91ba062d05c99c6cd2/internal/paths/paths.go#L148
For clarity there will be two things that need to be uninstalled:
$GOPATH/src/matthewmueller/joy
i read up a bit about go tools that allow for vendoring 3rd party stuff.
i came across https://github.com/Masterminds/glide which is up to the task.
The official dependency management tool https://github.com/golang/dep is not up to the task yet since it cannot handle non go dependencies that don't have go source files.
But they are actively working on that feature.
See https://github.com/golang/dep/issues/1306
This issue thread is particularly interesting since at the start of the thread you see an example of a glide YAML configuration file for vendoring external depencencies. In their case arbitrary binaries (compiled protocol buffers).
This is also related to issue https://github.com/matthewmueller/joy/issues/72
It would be good to an uninstall script.
As the install script is generated, I am assuming the uninstall could also be generated, if not I could submit PR.
Thanks