

Quick Python/Developer tips for OSX Lion - bellybutton
http://jessenoller.com/2011/07/30/quick-pythondeveloper-tips-for-osx-lion/

======
jnoller
I'll add more as they come up or people share them. I'm pretty happy with the
upgrade, and nothing broke for me, really. My VMWare Fusion system kept
chugging along, etc.

Also, full disk encryption is _amazing_

~~~
ConstantineXVI
Just discovered this The Hard Way, but if you run Boot Camp; make sure you get
the Boot Camp 4.0 update on the Windows side before you turn on FileVault. If
not; Windows will try to mount your Mac volume (which is now encrypted
gibberish), fail miserably, and BSoD every time within 30s of logging in. If
it's too late, booting into safe mode and renaming the HFS drivers
(AppleMount.sys and AppleHFS.sys IIRC) in C:\Windows\System32\drivers will get
your system out of limbo.

~~~
jnoller
Added a note to the OP; thanks.

------
angrycoder
1) Install iTerm 2, a better terminal

2) Install Alfred, disable the spotlight hotkey and assign Alfred to
Command+Space

3) Install Witch, a better command tab switcher that handles minimized
windows.

~~~
jnoller
iTerm2 -> Dislike, it doesn't offer me any benefits to my current workflow.

Alfred -> If you don't have this installed before upgrading to Lion, which the
article is about, then I think you might have something wrong with you :)

Witch -> Never used it.

~~~
riobard
I'm wondering what's your screen resolution? I'm using it on 1920x1080 +
1600x1440 dual screen. To me, the ability of iTerm2 to vertically and
horizontally split multiple terminals fullscreen on a big monitor is a huge
plus.

And for a lone time, Terminal.app before Lion only supports 16 colors, which
is a big reason for me to switch to someone better. iTerm2 fits the bill.

~~~
jnoller
I don't like splitting terminal windows - I use the tabs built into
terminal.app and sizeup (<http://irradiatedsoftware.com/sizeup/>) to
split/stack essentially "tab groups". I normally have multiple spaces, each
with 50% of the horizontal screen dedicated to vim, and the other 50% to two
groups of terminals (each one taking 50% of the vertical).

I'm not running dual screen - just 1900x1200 and 1440x900 depending on where I
am. Like I said, it's a workflow thing. I didn't even notice the increase in
terminal colors - all my good coloring is in mac vim, not in the terminal.

~~~
Pewpewarrows
The autocomplete and "instant replay" features are also very handy to have
when you need them (from iTerm2).

------
vonSeckendorff
The author states _Lion’s default Python install is a healthy Python 2.7.1._

I have personally had an unreasonable amount of trouble installing and using
Python libraries and environments on Snow Leopard. I think right now I have at
least 3 different versions of Python installed, each with various and
disparate libraries. Has this been addressed in Lion? Getting Numpy, Scipy,
etc to work is a chore; especially when comparing it to the Linux experience.

~~~
waterside81
I used to have trouble getting numpy and scipy installed - until I started
using homebrew. It blows MacPorts out of the water. Just make sure your
architecture is set correctly as Jesse outlines in this blog post, otherwise
you'll run into problems building the various C components with gcc.

~~~
jnoller
What he said; use homebrew - judicious use of homebrew and virtualenv will
save you lots of pain. I never install framework builds from python.org - I
don't like installing things into /Library or ~/Library

------
hello_moto
Haven't upgraded to OSX Lion and probably won't purchase MacBook anymore in
the future (I currently own a 13" MBP).

Setting up development environment in Linux seems more sane not just for
Python but for almost everything else (Java, Ruby, typical LAMP stack) except
if you're doing iOS development.

~~~
jnoller
I only do Linux/web development; and it never really bothered me. Of course,
I'm doing Python development, which means I rarely run into issues (and if I
do, homebrew fixes them easily). I also run VMware fusion with Ubuntu/Fedora
VMs for deployment testing. And throw in about 4 windows VMs for IE/compat
testing to boot.

So, I disagree that it's "more sane" - I spend plenty of time chasing down
crazy outdated versions of Python libraries the apt/yum repos contain, etc,
and well, I don't like spending my time in linux window managers (I dislike
the UI) so it's a wash, and getting a linux dev environment setup on my mac is
as simple as booting a VM and swapping it into fullscreen.

But to each their own. If I wasn't running OSX, I'd be running Linux. I just
prefer one OS' aesthetics over another.

See also Vagrant (<http://vagrantup.com/>) - runs off of virtualbox if VMWare
isn't your thing.

~~~
hello_moto
At some point in time in my life (I don't know when), I started to ignore the
UI of various OSes. Most of my time I spent in an IDE, browsers, and
occasionally a communication software (Outlook, LotusNotes, e-mail client,
whichever floats).

On the other hand, I thought people install Python libraries either directly
downloading the distributions or via easy_install? I never install modules
from apt/yum.

~~~
jnoller
_shrug_ \- Like I said, it's a matter of aesthetics and usability for me. I've
never met a Linux UI I liked (except for XFCE a long time ago), and I go out
of my way _not_ to use non-native apps on OSX. It's all about personal
preference. I also dabble in design and UI/UX, and have for some time, maybe
that's why.

ps. easy_install is bad for you, use pip! <http://www.pip-
installer.org/en/latest/index.html>

------
neutronicus
Huh. He said "need done" instead of "need to be done". I wonder if he's
originally from Pittsburgh?

~~~
jnoller
Alaska, actually. Where did I say that in the article?

~~~
neutronicus
Oh, this is embarassing - I thought I was commenting on the Android/iOS
article.

------
oasisbob
Has anyone had any success using the osx-gcc-installer he mentions? I'm really
curious how well it works in comparison to Xcode.

<https://github.com/kennethreitz/osx-gcc-installer>

------
null_para
By the way, does anyone know how painful is it to get Mysql working for Python
apps. Installing MysqlDB on Python was painfully excruciating process on Snow
Leopard.

~~~
orangecat
I've had good results with the pure Python "MySQL Connector":
<https://launchpad.net/myconnpy>

------
pama
For emacs: change the system-wide keyboard shortcuts for mission control
(Ctrl-up and Ctrl-down have better uses).

