Introduction to Bio-Linux
Introduction to Bio-Linux
Introduction to Bio-Linux
You also want an ePaper? Increase the reach of your titles
YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.
ls cat*hat<br />
list all files starting with the letters cat and ending in hat<br />
? matches a single character<br />
ls cat??hat list all files starting with the letters cat followed by any 2 letters, and then hat<br />
. “the direc<strong>to</strong>ry I am currently in”<br />
.. the direc<strong>to</strong>ry one level above<br />
~ my home direc<strong>to</strong>ry<br />
~username<br />
the home direc<strong>to</strong>ry of the user username<br />
Changing direc<strong>to</strong>ries<br />
The command used <strong>to</strong> change direc<strong>to</strong>ries is cd<br />
If you think of your direc<strong>to</strong>ry structure, (i.e. this set of nested file folders you are in), as tree structure, then the<br />
simplest direc<strong>to</strong>ry change you can do is move in<strong>to</strong> a direc<strong>to</strong>ry directly above or below the one your are in.<br />
To change <strong>to</strong> a direc<strong>to</strong>ry one below you are in, just use the cd command followed by the subdirec<strong>to</strong>ry name:<br />
cd subdir_name<br />
To change direc<strong>to</strong>ry <strong>to</strong> the one above the one your are in, use the Unix shorthand for “the direc<strong>to</strong>ry above” ..<br />
cd ..<br />
If you need <strong>to</strong> change direc<strong>to</strong>ries <strong>to</strong> one far away on the system, you could explicitly state the full path:<br />
cd /usr/local/bin<br />
If you wish <strong>to</strong> return <strong>to</strong> your home direc<strong>to</strong>ry at any time, just type cd by itself.<br />
cd<br />
To switch between direc<strong>to</strong>ries, you can use the cd – command. This returns you <strong>to</strong> the last direc<strong>to</strong>ry you were<br />
working in before this one.<br />
If you get lost and want <strong>to</strong> confirm where in the direc<strong>to</strong>ry structure you are, use the pwd command (push working<br />
direc<strong>to</strong>ry). This will return the full path of the direc<strong>to</strong>ry you are currently in.<br />
Note also that by default in <strong>Bio</strong>-<strong>Linux</strong>, you see the name of the current direc<strong>to</strong>ry you are working in as part of<br />
your prompt. This is <strong>to</strong> help you remember where you are in your account.<br />
Exercise<br />
Change direc<strong>to</strong>ry from your home direc<strong>to</strong>ry <strong>to</strong> the direc<strong>to</strong>ry intro_pract.<br />
cd intro_pract<br />
Type pwd <strong>to</strong> see the full path <strong>to</strong> where you are.<br />
6