I just got a new computer and wanted to see what it took to get it “all set up.” Each step along the way, I realized there were other things I wanted to set up, or little problems in the process, so I kept track of them, in the hopes that this will contribute to making the internet better. I have benefitted from many similar resources, so hopefully this will be of value to someone.
Additionally, I realized that after installing only a few programs and tools, the setup/development environment on your local computer is very unique–and probably a reason why “getting things to work” may often require lots of special fixes.
The setup on my last computer turned into an absolute disaster over time, so I tried to be very deliberate in creating a good setup, and really reading up on resources. Any comments? What should I have done better?
=======
Step 1. Open Safari.
Step 2. Download Google Chrome.
Step 3. While Chrome is downloading, clear random stuff from the dock.
Step 4. Done using Safari. Open Chrome. Needed application specific password to get logged in. https://www.google.com/accounts/IssuedAuthSubTokens
Step 5. Dock hiding on
Step 6. Open Messages and try to test that out.
Step 7. Open Terminal. Change theme.
Step 8. Open System Preferences. Change scroll direction back to the old way.
Step 9. Download Dropbox.
Step 10. Download Alfred (alfredapp.com)
Step 11. Try to set cmd+space as Alfred hotkey. However, that is already the keyboard shortcut for Spotlight. Go to System Preferences/ Keyboard Shortcuts and turn that off first.
Step 12. Configure Dropbox and hope all of my documents sync up.
Step 13. Download Divvy. mizage.com/divvy
Step 14. Configure Divvy, left side, right side, thirds, corners.
Step 15. Download Firefox. I’m not going to use it, but I feel like I should have it.
Step 16. Download Evernote. I used this a bunch many years ago. Completely stopped using it. Now am maybe going to try using it again. Using it to write up this whole thing.
Step 17. Download Spotify.
Step 18. Now on Evernote on the new computer. Sweet.
Step 19. Download Sublime Text 2. http://www.sublimetext.com/2
Step 20. Download OmmWriter. http://www.ommwriter.com/en/free-download-mac.html
Step 21. Tried to open OmmWriter, but got a message that “App can’t be opened because it is from an unidentified developer.” Fix from here http://osxdaily.com/2012/07/27/app-cant-be-opened-because-it-is-from-an-unidentified-developer/ was to go to System Preferences/Security and Privacy/Allow Apps from Anywhere.
Step 22. Big one. Download Xcode. This will probably take forever, especially since it is 1.6GB.
Step 23. Installed Google Hangout Plugin.
Step 24. Man. XCode installed. Took forever. XCode/Preferences/Downloads then install Command Line tools.
Step 25. Install Boomerang for Gmail.
Step 26. Get Python and stuff set up. I’m going to follow this guide for now: http://docs.python-guide.org/en/latest/starting/install/osx/
Step 27. Well the first direction to install Homebrew was off so I went here: http://mxcl.github.com/homebrew/ and did this
ruby <(curl -fsSkL raw.github.com/mxcl/homebrew/go)
Seems that /usr/local/bin was already on the path, so skipped that step.
Well it also seems the system already has python 2.7, so skipped that step.
Tried easy_install pip, but had permissions errors. Now I’m going to try the new python from homebrew.
Well, in trying to do that, I needed to install XQuartz. http://xquartz.macosforge.org/trac/wiki
Step 28. Download and install XQuartz.
Step 29. From http://hackercodex.com/guide/python-install-django-on-mac-osx-lion-10.7/ I changed my user to be the owner of /usr/local
$ sudo chown $USER /usr/local
Step 30. Testing out Homebrew by installing wget
$ brew install wget
Worked.
Step 31.
Now I found this guide, which seems to be good: http://metacog.tumblr.com/post/28333408639/setting-up-a-development-environment-on-mountain-lion For python it recommended this guide http://www.thisisthegreenroom.com/2011/installing-python-numpy-scipy-matplotlib-and-ipython-on-lion/#homebrew so I am doing this:
$ brew install python --framework --universal
It seemed that I had python 2.7.2 and the current version is 2.7.3.
Step 32. Create my .bash_profile and add this line:
export PATH=/usr/local/share/python:$PATH
so python will work properly. It also seems that pip was installed by that previous step.
Step 33. While I am figuring out what do do about the python symlink, install git
$ brew install git
Step 34. Well, I already had /usr/loca/bin in my path, but somehow it came after /usr/bin, so home-brew was not happy. I added this to .bash_profile
export PATH=/usr/local/bin:$PATH
Now brew doctor says it is ok. Now which python also gives me /usr/local/bin/python which I believe is what I want.
Step 35. Modifying the python Current symlink.
$ cd /System/Library/Frameworks/Python.framework/Versions
$ ls
2.3 2.5 2.6 2.7 Current
$ ls -al Current
lrwxr-xr-x 1 root wheel 3 Jul 21 19:25 Current -> 2.7
$ sudo rm Current
$ ln -s /usr/local/Cellar/python/2.7.3/Frameworks/Python.framework/Versions/Current
ln: ./Current: Permission denied
$ sudo ln -s /usr/local/Cellar/python/2.7.3/Frameworks/Python.framework/Versions/Current
Okay.
$ ls -al Current
lrwxr-xr-x 1 root wheel 75 Sep 18 23:32 Current -> /usr/local/Cellar/python/2.7.3/Frameworks/Python.framework/Versions/Current
Well, I did that. I hope the guy from http://www.thisisthegreenroom.com/2011/installing-python-numpy-scipy-matplotlib-and-ipython-on-lion/#homebrew knows what he is talking about. Seems like he does.
Step 36. Virtualenv.
$ pip install virtualenv
Step 37. Virtualevn Wrapper
$ pip install virtualenvwrapper
Step 38. Set up virtualenvwrapper
$ source /usr/local/share/python/virtualenvwrapper.sh
And then put that line in .bash_profile
Step 39. Not sure exactly how I want to install MySQL, so I’ll install Skype.
Step 40. Twitter for Mac.
Step 41. Install MySQL. Oh man.
$ brew install mysql
I read around a bit first, and you can type brew info mysql, this gives you a list of things to know about setting this up. The one interesting thing here is there is a section called “Caveats.” There are actually a lot of caveats with this installation so hopefully it will work.
Then to address the Caveats.
$ unset TMPDIR
$ mysql_install_db --verbose --user=`whoami` --basedir="$(brew --prefix mysql)" --datadir=/usr/local/var/mysql --tmpdir=/tmp
Then tried
$ mysql.server start
$ mysql
and it loaded! So that is good.
Then to get this to launch on startup, I did:
$ cp /usr/local/Cellar/mysql/5.5.27/homebrew.mxcl.mysql.plist ~/Library/LaunchAgents/
$ launchctl load -w ~/Library/LaunchAgents/homebrew.mxcl.mysql.plist
Haven’t tested that it actually launched yet, though.
Step 42. Symlink:
$ ln -s "/Applications/Sublime Text 2.app/Contents/SharedSupport/bin/subl" /usr/local/bin/subl
Step 43. Copy .vimrc over
Step 44. Copy .gitconfig over
Step 45. Create .bashrc. Move contents of .bash_profile over there, and set .bash_profile just to
source ~/.bashrc
Step 46. Add a few helpful terminal aliases to commonly used directories.
alias myalias='cd my/favorite/directory'
Step 47. Modify the shell prompt. This is a new one that I like. Add this to the .bashrc
# Set the prompt
PROMPT_COMMAND='DIR=`pwd|sed -e "s!$HOME!~!"`; if [ ${#DIR} -gt 30 ]; then CurDir=${DIR:0:12}...${DIR:${#DIR}-15}; else CurDir=$DIR; fi'
PS1="jbk[\$CurDir] \$ "
From http://lindesk.com/2009/03/customizing-the-terminal-the-prompt/
Step 48. Move over the private key and public key to the .ssh directory and set the proper permissions. The private key is 600.
Step 49. To get everything else working for django
$ mkvirtualenv codehs
$ pip install django
$ pip install south
$ pip install django-extensions
Mysqldb problems.
$ pip install MySQL-python
Step 50. CodeHS runs locally again.
Step 51. Download VLC.
Step 52. Download Jing.
Step 53. Well, it seemed that Jing needed Adobe Flash Player, even though Chrome already has it. So download that.
Cool setup list mate!
Other things I like are:
Total Finder:
http://totalfinder.binaryage.com/
Sublime Text 2 packages:
https://gist.github.com/3293504
Rupa/z
http://www.simonowendesign.co.uk/easier-changing-directory-in-terminal-for-mac-os-x-using-rupaz/
Looking into yeoman as well:
http://yeoman.io/
Hey Simon–
Glad you liked it! And thanks for sharing those other suggestions. I have some of those SublimeText2 packages, but TotalFinder seems like a good one to check out.
Hello There. I discovered your weblog the use of msn. That is a very well written article. I will be sure to bookmark it and return to learn more of your useful information. Thanks for the post. I will certainly comeback.
Glad you found the Hacker Codex posts useful. Let me know if there are any suggestions for improvement.
http://hackercodex.com/guide/mac-osx-mountain-lion-10.8-configuration/
http://hackercodex.com/guide/python-virtualenv-on-mac-osx-mountain-lion-10.8/