DeepSourceCorp / cli

Command line interface to DeepSource
https://deepsource.com
BSD 2-Clause "Simplified" License
50 stars 18 forks source link

changing default installation location from $HOME/bin #53

Closed Bhupesh-V closed 3 years ago

Bhupesh-V commented 3 years ago

Is your feature request related to a problem? Please describe. So the script at https://deepsource.io/cli is not really opensourced, that's why reporting this here:

the default location space for linux systems is generally $HOME/.local/bin/ this has an advantage to make the command deepsource beng invoked from anywhere in the system since the bin location is included in $PATH by default.

Describe the solution you'd like Either we export the $HOME/bin to users $PATH env or change the default installation location

siddhant-deepsource commented 3 years ago

Hey @Bhupesh-V 👋

Thank you for this amazing suggestion. This will indeed be a great improvement. We have been working to add new features to the CLI and have added this to the project roadmap as well. We will surely implement and ship it in upcoming release.

Thanks 🙌

siddhant-deepsource commented 3 years ago

Hey @Bhupesh-V,

The CLI now supports an environment variable BINDIR which you can set to download the binary in a custom location (default is ./bin/deepsource). Thus, in order to make sure it executes globally, you can now install it in the set PATH by supplying it as an environment variable.

Example :

BINDIR=~/.local/bin curl https://deepsource.io/cli | sh

Adding to this, we are also working towards adding support for installation of DeepSource CLI using popular package managers. That will surely make things a lot easier in future.

Thanks for the suggestion 🙌