Find » Technology » Tutorials » Computer Tips: Learning the Basic U...

Computer Tips: Learning the Basic Unix Commands

How Mac and Linux Users Can Escape the Windowed Environment

By Matthew Ferri, published May 28, 2007
Published Content: 2  Total Views: 123  Favorited By: 0 CPs
Embed:  
Rating: 3.0 of 5
If you ask a person whether or not they know how to move around files and folders on their computer, the answer is usually yes. That is, if they are allowed to use windows. Before the age of the graphical user interface, all computer users knew only one way to do things: the text terminal.

The vast majority of programmers and serious computer users still use it simply because it's faster. You don't move your hands back and forth from the mouse to the keyboard while you try to keep all the information you need on screen. When you use the terminal, everything you need is clear and easily readable. All you have to do is spend a few minutes learning the basics.

This tutorial will focus on the Unix commands. If you aren't using Microsoft Windows, you probably have a Unix or Unix like terminal available to you. On a Mac OS X system, the terminal application is in Applications/Utilities.

Moving Around:

The first command you should know is pwd (print working directory). This simply tells you your current working directory. When you enter a command on a file without an absolute path (I'll get to this later), it looks for the file in this directory.

If you want to know which files are in that directory, use the command ls. It will output the name of each file and directory in your current working directory. Ls -a will also output hidden files. In Unix, a file is considered hidden if the filename begins with a period. Ls -l lists the files along with their various attributes.

Now that we know where we are and what is there, we need to know how to move around. The change directory command is cd. To change your current working directory to another in your working directory, type cd followed by the name of the directory. If you want to go up a directory, use ".." as the directory name.

Computer Tips: Learning the Basic Unix Commands

A typical terminal window

Credit: Matthew Ferri

Copyright: Matthew Ferri

Comments
Type in Your Comments Below - (1000 characters left)
Your name:

Submit your own content on this or any topic. Get started »
Most Commented On