Open a terminal (doesn’t matter what directory you’re in) and run the following command:
sudo easy_install csvkit
By “run the command” I mean type all that at the prompt and hit return. OSX will ask for your password. Enter it.
If you get an error, skip to step 3, below.
CSVkit is a suite of utilities written in
Python. It is available as a Python module, which means we can use one of Python’s module installers to install it on your computer. OSX ships with easy_install by default, but like a lot of people, I prefer
As it turns out, OSX ships with
easy_install. This isn’t a python class or a programming class, it’s a data class and all I really want is to walk you all through how you might dig in to a monster CSV file with some command line tools. For that, it really doesn’t matter how you install CSVkit as long as you install it.
So here are some good options:
Install Homebrew. Then do
pip install csvkitat the command line. If you get an error that suggests you don’t have permission to install it, try
sudo pip install csvkitto install with root privileges. Try
man sudoif you want to understand what the command does. If you want to explore more programming, this is probably your best option.
Alternatively, you can install
sudo easy_install pip) and then install CSVkit with
sudo pip install csvkit. Choosing this option won’t mean you can’t install Homebrew later.
If you don’t have admin privileges on your computer, you’re going to have to do some fancy footwork no matter what. Head over to my notes on installing CSVkit for a rundown of instructions.
If you run into trouble, let me know what the trouble is.