fishworks / gofish

Keep your fish fresh! :tropical_fish:
https://gofi.sh
Apache License 2.0
811 stars 64 forks source link

Create symlinks under $GOFISH_BINPATH #174

Closed mumoshu closed 3 years ago

mumoshu commented 4 years ago

This fixes go-fish install to use $GOFISH_BINPATH when installing foods.

To be clear, go-fish init had been correctly using $GOFISH_BINPATH to override the default bin path(e.g. /usr/local/bin on *nix) to be created. So, I had expected go-fish install to install binaries under the path go-fish init created, but it didn't.

This patch updates gofish install to create symlinks under $GOFISH_BINPATH if set, so that the behavior is consistent with init.

mumoshu commented 4 years ago

Updated the PR description to better explain what I tried to "fix".

mumoshu commented 4 years ago

@bacongobbler I'd appreciate it if you could review this 😃

bacongobbler commented 4 years ago

Hey! Sorry for the delay. Will review after the Labour Day long weekend. Cheers!

bacongobbler commented 4 years ago

Okay, just getting back from vacation.

So, I had expected go-fish install to install binaries under the path go-fish init created, but it didn't.

It was intended by design to symlink binaries under /usr/local. $GOFISH_BINPATH should point to /usr/local/bin on linux and MacOS, and C:\\ProgramData\bin on Windows.

Based on that information, I'm not entirely sure what you are attempting to fix here. Can you please open a new issue and clarify what issue you are trying to solve? A test case would be helpful as well.

Keep in mind that it is entirely possible a user would want to install packages into locations other than /usr/local/bin. For example, manpages may want to be installed under /usr/local/man, and libraries under /usr/local/include. Hope that clarifies the current behaviour.

Thank you!

mumoshu commented 4 years ago

@bacongobbler Welcome back 😃 I've created #176. Hoping it explains my issue better.

bacongobbler commented 3 years ago

closing as stale/moving forward in favour of PRs that implement #150.