|
|
Glossary
- path
In Unix, a path is a list of directories. A path can be either absolute
(starting with a "/" like /usr/bin), or relative (starting from
the current directory) like src/cosc1410/assn1.
PATH can have another meaning in Unix, the $PATH variable in most shells
represents all the directories that are searched to find commands you type
at the shell prompt. (e.g. /bin:/usr/bin:/usr/local/bin would allow you to
find the ls binary in /bin/ls.)
- Open Source Software
- Software that is free for the public to use, change, modify, republish
(with credit to the original authors a typical stipulation). Typically
includes the source code used to create the software. See
http://www.opensource.org/ for
details about the Open Source Initiative
- perl
- Perl is a programming/scripting language that has tremendous
text-processing capabilities. See perl.org
- Shell
-
See explanation here
- Standard Error
-
Also known as STDERR, standard error is an output stream out of a program
that allows it to print error messages on a separate conceptual stream
than the program's normal output.
$ ls -Fa / /thisfiledoesntexist
/usr/local/bin/ls: /thisfiledoesntexist: No such file or directory
./ bin@ export/ lost+found/ platform/ tmp/ xfn/
../ dev/ home/ mnt/ proc/ usr/
.bash_history devices/ kernel/ net/ root/ var/
auto/ etc/ lib@ opt/ sbin/ vol/
$
The first line of output, the error message saying that the file,
/thisfiledoesnotexist actually does not exist, is printed to STDERR, while
the rest is printed to STDOUT (see below).
$ ls -Fa / /thisfiledoesntexist > ls_of_root.txt
/usr/local/bin/ls: /thisfiledoesntexist: No such file or directory
$
In this example, we redirect the output of ls into a file, so the only
thing that gets printed is the error message.
- Standard Input
-
Also known as STDIN, standard input is an input stream into a program. In
Unix, the STDIN of a program you run is usually drawn from the console.
$ cat
Now I am typing into the standard input of cat. Press ^d to exit.
Now I am typing into the standard input of cat. Press ^d to exit.
^d
$
What happened here is that cat, without a filename to read, accepts input
from STDIN, and outputs to STDOUT (see below). Every line we type is
immediately echoed back at us.
- Standard Output
-
Also known as STDOUT, standard output is an output stream out of a program.
Most programs you run in unix output to STDOUT, e.g. ls, cat, more.
-
|