Sie sind auf Seite 1von 26

Intro to the Command

Line
Elise Harris

You Need a UNIX Command Line


to...
1. Install software needed to deploy Ruby apps
2. Install software needed to deploy Rails apps
3. Install Homebrew or Node (a platform built
on JavaScript that does a lot of back end
data work usually done by languages like
Python or frameworks like Rails)
4. Do complex operations for other languages

and also to ...


5. Install Ruby gems like Sass
6. Use git
7. Push your locally hosted code up to Github
or Bitbucket
8. Install and use Heroku, a site that hosts
Ruby on Rails apps

Why You Should Care

Check out these


instructions for
installing Ruby on Rails

FEAR
IS
YOUR
MAJOR
ENEMY

Fear Not
I use Linux on a USB because there are no viruses or
intrusive updates. And no planned obsolescence. But
another reason to use a USB-hosted operating system
is anxiety-free terminal experimentation. You can try
out all the scary-feeling commands knowing you are
only risking an $8 investment. Later, you can use these
same commands on your Mac. Or learn the equivalent
commands for Windows.

Main reasons to use Linux


Watch later if you
feel like it. This is
just user
experience stuff,
not politics of
corporate
monopoly.

Making a Linux OS on a USB


Three easy setup steps
1. Download the Universal USB Installer from
PenDrive Linux
2. Download the latest stable (LTS) version of
Ubuntu (or any other distribution) from their
site
3. Insert your 7 or 8 G USB flash drive

Try and Try Again to Install


Open the installer.
Dont get discouraged
if it doesnt work the
first time. It takes
everyone multiple
tries. The Installer
interface is at right.

The Persistent File


Following the steps is pretty self explanatory.
The installer sometimes takes a while to
recognize your USB drive. Click the little box. If
you choose to install significant memory (like a
4G persistent file, the max allowed when I tried)
download will take a while. Ive had it take 16
minutes and 26 minutes, depending on what
else was going on.

Links to more detailed explanations are here:


For Mac users
For Windows users
Using Virtual Box
Tux, the Linux mascot

The Code: The Story of Linux


Cool doc when you have an hour.
Double click on image to the left to
start video.
Make sure you put subtitles on to
understand speakers from all over
the world. Especially Torvalds
father.

What *was* the terminal?

What *is* the terminal?


a tool in
any
operating
system.
but most
people
dont
need to
use it.

Four crucial guides


a prereq for most coding bootcamps. short.
The Command Line Crash Course
another intro to command line. long.
Linux Command
the free Harvard class CS50 explains terminal
commands in detail. on edX or here.

A pretty good video on terminal 101


This uses Redhat
but the commands
are the same once
you get past intro
and into terminal
part. Double click
to start.

Basic Commands
List the Files on your computer: ls
Look at your memory: free
Look at your CPU: top
Look at your processes: ps

Navigating Directories (=folders)


pwd= present working directory
mkdir=make directory
cd= change directory
Link here and here for fuller description

grep x= search for x


Here are good examples

Using the pipe


This pipe or vertical bar
is shift backslash.
On upper right hand
of keyboard.
Connects
different
commands.

Man files (=manuals for commands)


Traditionally, manuals explaining each
command are read on the terminal. You can
type man then the command name. You can
also read them here. And on linuxcommand.org
You cant learn the terminal commands quickly.
You will need to read documentation.

Try Git on Code School


This free course helps you use the git
commands on a terminal emulator

Install Sass using command line


Here are instructions

Watch the Lynda course


Its for Mac users but UNIX commands are
universal. Click UNIX for Mac OSX Users.
Watch sections 1-8.

Two Last Resources


All the slides and homework from my GDI Linux
class are here at my Dropbox
And as Elvis recommended, check out cloud9,
an IDE with a terminal simulator. A good place
to experiment.

Das könnte Ihnen auch gefallen