A list of commands commonly used in Linux.
nedit
in any terminal windowpwd
: prints the name of the directory you are currently inls
: lists the contents of the current directorycd
foo : change to the directory named "foo"mkdir
foo : create a new directory named "foo"rmdir
foo : remove the directory named "foo". NOTE: this permanently removes the directory, so use with care!Shortcuts:
cd
by itself returns you to your home directorycd ..
changes to the directory directly above the current one (the "parent" directory)more
foo.txt : displays the contents of the file named "foo.txt"rm
foo.txt : removes the file named "foo.txt". NOTE: this permanently removes the file, so use with care!cp
foo.txt foo1.txt : copies the file "foo.txt" into the file "foo1.txt". Preserves the original file.mv
foo.txt foo2.txt : moves the file "foo.txt" into the file "foo2.txt". Removes the original file.man
foo : displays a help ("manual" page) for the command "foo", if one exists.hsp
foo.txt cs117
: submits the file "foo.txt" via the homework submission program (hsp
) to the cs117 folder.hsp -h
: help for the hsp
program. hsp -c cs117
: checks what files you have submitted via hsp
. nedit &
opens NEdit in the background.nedit
foo.txt opens the file "foo.txt" in an NEdit window.javac
Foo.java : compiles the program "Foo.java"java
Foo : runs the Java program contained in the file "Foo.class"Last updated by Amy Csizmar Dalal (email: adalal at carleton dot edu), Department of Mathematics and Computer Science, Carleton College, on Tue Sep 14 13:03:04 2004