This is an incredibly dumb question, but I don’t know the answer. Apologies in advance.
I want to download a repo of someone else’s code from GitHub to work on it. In a Unix-y filesystem, where is the most conventional place to put it?
I’ve been reading about standard directory structure on Wikipedia and it looks like below opt might be the most appropriate place. Is that correct?
I’m using MacOS, so the alternative would be for me to create a custom folder under /Users/me, but I wondered if there was a conventional place for working on code within the standard Unix directories.
It depends on your usage plans. If this is code you want to hack on, typically your home directory is the right place, since this is private to your unix user. I personally make a ‘dev’ subdirectory and put code in there (mine or other people’s, via github).
If you’re looking to install this software system-wide, the answer varies slightly by the system. /opt is a reasonable choice in most cases, as is /usr/local.