here's a few newbie questions from someone who has spent 15+ year coding in Windows but is starting from scratch on Mac OS X. I have searched the web and this site and not found answers, but I think the answers will be useful to a lot of people.
Very simply....
where should I store private code and projects in the file system? My user directory? In /usr/?
where should I store shared code and projects?
where should I set up a github repository?
once built, where should I install applications? I see lots of possibilities here. /opt/, /var/lib, /usr/local/var etc.
perhaps most interesting of all: how can I get a simple run-down of the location of everything that has been installed on my Mac?
I would imagine that over the 40 years of UNIX history some standards have emerged for these but so far I have been unable to find them. There must be some 'best practice' guidelines that I should follow.
Oh by the way I'm talking about things like PostgreSQL and such like. Not proper Mac applications.
The reason I ask is that I've come across a variety of ways to install things that seem to have their own ideas of where to install the same application. e.g. homebrew, ant, etc. These sometimes result in different installation locations than following an FAQ or documentation for a manual installation of the application.
Appreciate any answers on these.
Many thanks.
Github has a very nice Mac application that can download and sync your Github repositories. By default it places them in subdirectories within ~/Documents (your home folder's documents directory).
My home setup is to create a git directory inside ~ and just use that for private projects. For shared projects, place them in /Users/Shared (there's a common share folder in Mac OS for everyone)
As far as installing command line tools, Macs are like BSD boxes.. install in /usr/local/bin etc. Graphical applications should go in /Applications. Github's mac app installs a command line tool (optionally) in /usr/local/bin.
Some package tools on OS X create their own directory hierarchy (fink, macports), but mirports installs in /usr/local.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With