Where to Install Heroku CLI


#1

I know this is probably a dumb question, but I’m doing the “Your First Rails Application” section of the course, and I’m wondering if it matters where I install the Heroku CLI. I actually finished all of this last night but ended up nuking the whole thing because I’m pretty sure I screwed something up. So my question is: when installing the Heroku CLI, does it matter much what directory it goes in? Should it go straight in “my_first_rails_app”, should I create its own directory, or something else entirely? I’m sorry for the long-winded post and likely obvious question. I’m still really new to this. I appreciate anyone who takes the time to read this, thanks!

Edit: Okay I just created a directory for it and then ran [curl https://cli-assets.heroku.com/install.sh | sh] After doing an ls on the directory I made, I can see that heroku isn’t stored there regardless of running the command in there. If anyone wants to shed some knowledge about what is happening, I’d appreciate it. I think I’ll be alright though.

Edit2: Okay I actually do need help. I installed it in my default user ~ directory but now I’m pretty sure it needs to be in a local git repository. I’m uninstalling the cli and trying again from inside “my_first_rails_app.”


#2

curl downloads the contents of the link you give it, and then | is a pipe which pipes the contents of that file to sh. sh is the standard name for the shell (terminal).

The file will install it in the correct place. You shouldn’t need to worry about it doing anything else. Why do you think it didn’t install properly?


#3

Thanks for the clarification! And I wasn’t sure if I did it right simply because I’m using Ubuntu and I’m completely new to Linux, so still getting the hang of things. I’m not very knowledgeable about computers in general yet, but Linux is a whole different story. I keep thinking I’m going to break my computer by installing things wrong or just looking at my terminal funny. Thank you again, though! I really appreciate your explanation.