Command me, baby: Learn to love your shell.
This post contains language intended for an audience over the age of 13.
Hi, I’m Neil. I get paid to tell computers what to do. If you’re down, I’d like to show you how.
I’m sure you’re skeptical. In my time in this profession I’ve repeatedly encountered a widespread misconception that I, like all other ‘coders’, am somehow built or wired differently so that I’m able to comprehend these alien languages. No, I’m not. Sure, I graduated an Ivy League school with a BS in Computer Science. But I graduated with a 2.1777 GPA (which was probably also my BAC at the time), and taught myself infinitely more during my three years out than they taught me during my six years in.
So while Columbia may have given me a solid foundation for learning how to do this, it was still just patience and hard work that gave me the hard skill that’s becoming more relevant and valuable every day. The hard skill that’s the reason my offer to work a dream job with Gary and AJ Vaynerchuk at any cost was one they couldn’t refuse. The hard skill that gives me the confidence of independence — I know I’ll never have to rely on any person (or worse yet, any heartless corporation) for my personal well-being or my future prospects.
If that sounds nice to you, please read on, because I want to teach you everything I know. You must know first that what it took fundamentally for me to get to this level was patience and a basic capacity for analysis, and you will need to possess both of these traits. If you’re either impatient or irrational, embarking on this journey with me will be fruitless for you. I won’t judge you though; I don’t mean either of those adjectives in a derogatory manner. Both of those characteristics have their advantages: for example the impatience-irrationality combo is a pre-requisite for working in advertising. Don’t forget that those people make a shitload of money and have their work seen by millions. So, you know, no offense if you’re not into it…I get it, no worries, catch you later.
Now, remember what I said about patience? That means I’m also not going to employ the common methodology of teaching you in a frantic manner while exploiting your desire for instant gratification, using the infomercial “lose your gut in 20 days” pitch seen most often in this consumer culture of ours. You’re learning how to coax your shell into commanding an army of robots. You’re not going to become a general painlessly, in 45 minutes, by following 15 easy steps. The posts in this series will have such a slow, steady flow that you’re not even going to want to retweet them because none of them will be compact, self-contained bundles of knowledge.
As Queen Gorgo said in the 300, “this will not be over quickly. you will not enjoy this”
I mean, computer theory has been around since at least John von Neumann, who died in 1957 (before a computer had been invented, by the way). It took me two years of study and three years of practice to learn everything I know, there’s no way I could explicate it for you in a day. That’s why this is part 0 of a 42 part series.
Every Monday for the next 9.5 months I’ll put out another digestible morsel that will slowly build your knowledge base to the point that you can competently command and control your personal computer as well as any remote machine. I’ll teach you how to set up, troubleshoot, and customize a web server and a database. I’ll give you an introduction to all the tools you’ll need and a basic fluency that will let you provide value for either your own projects or a client’s. Exciting stuff, I know.

Plus, my writing style is approachable enough that if you just follow along casually, before you know it 9.5 months will have gone by and you’ll actually know what to do when faced with that ominous command prompt. The fact that this will take almost the same duration as the human gestation period is not lost on me. What you’ll have nurtured into existence by the end of this is the foundation to be able to write codes into your computer that generate money. As Curtis Jackson a.k.a. 50 cent said, “have a baby by me baby, be a millionaire”.
One last thing I want to mention before we get started is that if you ever have a question about something you read here, or want clarification on a term or are running into errors, please write in the comments or e-mail me nsarkar {at} vaynermedia {dot com} or tweet at me @neilsarkar — I promise I will respond.
Now I know you have a short attention span so today, since you took the time to read or skim most of what’s above, you only have to learn two simple things. How to open a terminal session, and how to find out where you are once you’re there.
0. Oh, hello.
If you have a Mac it’s as simple as command-space, type ‘terminal’, and click the result that your spotlight search brings up and it will open a shell window for you.

If you’re on Linux, you know how to get to the terminal already and you probably don’t need to read the first month of these articles.
If you’re on windows, you’ll have to download cygwin, which emulates a shell environment on your local filesystem. I’m not going to hold your hand on that one though, sorry. If you can’t afford a Mac then I’m sorry you have to go through this on an unfriendly operating system. If you can though, it was your choice to go with the status quo and unfortunately for you, when you place yourself in the middle of the bell curve you have to work harder than if you’re on one of the extremes. It just seems easier in your head because so many others are doing it the same way. Moving on.
1. Where am I?!?!?
The first thing you’ll need to know on a frequent basis is what directory you are currently in. The command that your computer is programmed to understand for this is “Print Working Directory”. If you’ve ever looked over a coders shoulder though, I’m sure you’ve noticed lots of short, cryptic, consonant-heavy pseudo words. That’s because you have to type A LOT into terminals to do anything of value, so pretty much everything is abbreviated to the maximum extent it can be without losing its meaning. Thus, the command that translates into Print Working Directory is pwd.

I’m sure it doesn’t excite you that you entered a simple command and the computer responded by printing information back for you to read. But you should be excited, goddamnit. You just communicated directly with your computer. You may use it every day, but you likely have no idea of the power you just harnessed directly.
How long would it take you to subtract 42.655 from 111.1?
This guy can do a billion squared algebra problems like that in a second. 10 to the power 18 per SECOND. 1,000,000,000,000,000,000 floating point calculations before you could finish reading the gaudy number at the beginning of this sentence.
Did you like Rainman?
You just made your acquaintance with the most powerful idiot-savant in the known universe.
Do you find talking to your friends using soundwaves to be an efficient means of communication?
Try the motherf*cking speed of light.
Your robot pal will do anything and everything you want it to, as long as you’re patient enough to ask it in a way it understands. One day, it will even make money for you. You just have to learn how to give it the right commands.














Add your comment!
So. Good.
Does PWD = “yo computer, i want to talk to you”?
Where the heck is the cliff notes?!?!??!
I’M GOING TO FAIL THE MIDTERM. I WORRY FOR MY POOR HAMSTER’S LIFE.
very cool.
i am, however, using cygwin on my pc today (an accountant has to have a PC;)) and mine says, “Owner@DG47N651~
$”
for my command prompt. I’m looking forward to learning how to command the commander to say ‘command me, baby’
I want to be able to click on ‘Neil Sarkar’ and go to other articles written by Neil Sarkar.