1. Macports install poem
After fresh OSX Lion install, install Macports to bring all the goodies of open source software to your computer. This will help get things running in shell and set up smooth Python development environment
sudo port install python32 python27 subversion perl5 nodejs npm \ rsync sqlite3 wget curl py32-virtualenv py27-virtualenv \ wget unrar zsh bzr bzip2 openssl jpeg libpng libxml2 libxslt \ git-core git-extras coreutils lesspipe findutils highlight grep +with_default_names
2. GNU Userland
Then enable Macports GNU userland commads put the following into your shell .rc file:
export PATH=/opt/local/libexec/gnubin:/opt/local/bin:/opt/local/sbin:$PATH export CLICOLOR=1 export LESSOPEN='| /opt/local/bin/lesspipe.sh %s'
This will give you nice colours in ls, etc. improvements over barebone BSD userland commands.
3. Sane text editor
Use your favorite non-terminal text editor from command line. Here is an example for Sublime Text 2 which is one of software developer text editors seeing active development under OSX
# Use Sublime Edit 2 as text editor inst export EDITOR="'/Applications/Sublime Text 2.app/Contents/SharedSupport/bin/subl'" alias subl="$EDITOR" # Open file in a real text editor, # if you happen to type nano from your muscle memory alias nano="subl"
ZSH is a popular shell among power users with all kinds of plug-ins available. They will help you to deal with Git repositories, virtualenvs, and so on…
To change your shell to Macports‘ /opt/local/bin/zsh in System Preferences > User & Groups: right click on your user after unlockingthe dialog window.
I am also working with some friends with a zsh installer Ztanesh which comes with more powerful default settings for OSX and Linux.
6. Disable Spotlight
Disable Spotlight indexing for better performance. Who uses Spotlight search anyway when you have grep?
sudo mdutil -i off /
Disable it also for your Legacy Filevault volume if you have one:
sudo mdutil -i off /Users/moo
7. Sync your configuration files
Some files you might want to save to your Dropbox etc. cloud storing service to share between your computers
- .ssh/ folder
- .gitconfig (sane .gitconfig example making git a bit less pain)
- Store Skype chat history in Dropbox
8. Kill alt + spacebar character
Pressing alt+spacebar accidentally creates an invisible character which causes most source code go hayware. Disable this behavior.
9. All Python versions
They can be built with collective.buildout.python recipe. In the case you need to deal with ancient codebases (*cough* Plone 3 *cough*).
10. Still some open questions….
All hints and pointers welcome for the following
- Sane command-line interface for git needed
- Firefox add-on for searching private Google Apps and email
- Edit-text-files-over-SSH using a local text editor