Cooking the perfect steak
via the Linux Command Line

by Code Snipcademy on April 1st, 2015.


Many tech-users nowadays do not understanding the power and flexibility that the Linux Command Line presents. Thus, they turn towards graphical user interfaces that not only slow their speed in getting things done, but also limit their ability to handle complex tasks.

In order to realize the power of the Command Line, we'll go over how one can easily cook the perfect medium-rare steak using nothing but a command line interface. Hopefully after seeing how easy it is to do this, people will invest the time to learn the command line and understand why professionals use it almost exclusively in their work.

Checking your fridge for a steak

The first step to cooking a perfect steak is to check the fridge contents to see if we have any steak. We do this simply by changing directories to our Kitchen, and listing the contents of our Fridge.

~$ cd ~/Kitchen/Fridge
Fridge$ ls -l 
-rwxr--r--@ 1 snipcademy staff 1542 Nov 13 13:12 kimchi drwxr--r--@ 1 snipcademy staff 8715 Nov 28 08:06 Leftover-thanksgiving-food -rwxr--r--@ 1 snipcademy staff 312 Dec 12 15:55 cheese-swiss -rwxr--r--@ 1 snipcademy staff 152 Dec 25 12:32 ketchup -rwxr--r--@ 1 snipcademy staff 973 Feb 05 08:13 plums -rwxr--r--@ 1 snipcademy staff 893 Feb 09 09:06 potoatoes -rwxr--r--@ 1 snipcademy staff 233 Feb 15 15:18 orange-juice -rwxr--r--@ 1 snipcademy staff 6704 Feb 25 09:07 cheese-parmesean -rwxr--r--@ 1 snipcademy staff 1804 Feb 12 11:28 sour-cream -rwxr--r--@ 1 snipcademy staff 123 Mar 03 10:16 raspberry-sauce -rwxr--r--@ 1 snipcademy staff 873 Mar 15 13:06 chicken-broth -rwxr--r--@ 1 snipcademy staff 239 Mar 18 08:17 broccoli -rwxr--r--@ 1 snipcademy staff 220 Mar 19 11:07 tomatoe-sauce -rwxr--r--@ 1 snipcademy staff 143 Mar 23 13:34 milk-2% -rwxr--r--@ 1 snipcademy staff 193 Mar 30 12:11 eggs

Removing expired foods

Ok, wow. Let's get rid of some expired foods.

Looks like we have kimchi from November. That should be ok. They say that the older the kimchi

, the more flavorful it is.

But this swiss cheese has got to go...

Fridge$ rm cheese-swiss

And so does this Leftover Thanksgiving Food...

Fridge$ rm -r Leftover-thanksgiving-food

Welp. Guess we have no steak.

Going out to buy a steak

Okay, let's now go to the grocery market. Luckily, I planned ahead and shortcutted the process by setting up an alias to get to my local grocery store.

~$ alias groc='cd /usr/local/Market'

Alright. Let's go to the Market now.

~$ groc
Market$ cd Meats

We can filter all the food available by pipelining our results into grep.

Meats$ ls | grep steak
filet-mignon-steak     flank-steak       ribeye-steak
prime-rib-steak        tri-tip-steak     new-york-prime-beef

Cool. Let's just check how much this new-york-prime-steak costs with the wc command and its -c option for cost.

Market$ wc -c new-york-prime-beef
9.12 USD

Not bad. Time to checkout with git.

Market$ git checkout new-york-prime-beef
Are you sure you want to purchase new-york-prime-beef for 9.12 USD [Y/n]? Y
Enter pin:
Transaction complete.

Let's get back home to our home (~) Kitchen to cook this thing!.

$ cd ~/Kitchen

Checking our manual on how to cook steak

The Command Line has a built-in manual for all commands. That means we don't even have to Google anything to figure out how to perform tasks!

Let's open up the manual page for steak.

Kitchen$ man steak
steak manual

Okay great! Everything we need is in our manual page. How convenient is that?

Marinating the steak

Now let's place salt and pepper on our steak, then drizzle some olive oil and sprinkle fresh thyme leaves. Simply pass in the options noted in the man page.

Kitchen$ steak -opst -n 240 new-york-prime-steak

Now we'll just let it sit for about 4 hours (240 min).

Raw steak with salt, pepper, olive oil and thyme

Cooking on the stove

Now we're going to take out a large pan and put some olive oil on it at medium-high heat (if you're unfamiliar with how to use a Pan, check out its man page).

Kitchen$ pan -m olive-oil

Then we'll cook the steak on one side for about 4-5 minutes, then the other side for 3-4 minutes.

Kitchen$ mv new-york-prime-steak Pan
Kitchen$ cd Pan
Pan$ steak -b -n 4 new-york-prime-steak!
Pan$ steak -f new-york-prime-steak
Steak flipped.
Pan$ steak -b -n 3 new-york-prime-steak!
Raw steak in a pan Cooked steak in a pan

Oven bake

Let's now pop it in the oven for about 10 minutes until it reaches medium-rare, or longer if you want your steak to cook more.

Kitchen$ oven --bake 400
...preheat on...ready!
Kitche$ mv new-york-prime-steak ../Oven
Kitchen$ oven -t 10

Butter baste

Here comes the most important part. We're going to take out a large pan and melt some butter on it, then baste our steak on both sides.

Kitchen$ pan -m butter
Kitchen$ mv Oven/new-york-prime-steak Pan/
Kitchen$ cd Pan
Pan$ steak -b -n 4 new-york-prime-steak
Pan$ steak -f new-york-prime-steak
Steak flipped.
Pan$ steak -b -n 3 new-york-prime-steak
steak basting with butter

Serve and Enjoy

Alas, we can now add, commit and push our perfect steak to production. Serve with mashed potatoes, asparagus and a side of salad.

Kitchen$ git add .
Kitchen$ git commit -m "Cooked my first steak via the command line"
Kitchen$ git push
steak ready to serve

Finishing note

Wasn't that great? Now if I have you convinced, try checking out our command line tutorial series today to learn how to do more than just cooking a steak!

Take your Linux skills to the next level!

How Linux Works

Take your Linux skills to the next level! Try Linux & UNIX

In this completely revised second edition of the perennial best seller How Linux Works, author Brian Ward makes the concepts behind Linux internals accessible to anyone curious about the inner workings of the operating system. Inside, you'll find the kind of knowledge that normally comes from years of experience doing things the hard way.

$ Check price
39.9539.95Amazon 5 logo(114+ reviews)

More Linux & UNIX resources

Aching back from coding all day?

Acupressure Mat & Pillow

Aching back from coding all day? Try Back Problems

Relieve your stress, back, neck and sciatic pain through 1,782 acupuncture points for immediate neck pain relief. Made for lower, upper and mid chronic back pain treatment, and improves circulation, sleep, digestion and quality of life.

$$ Check price
144.87144.87Amazon 4.5 logo(1,890+ reviews)

More Back Problems resources