Linux Shell Scripting



Syntax: man command-name
Syntax: info command-name
See what happened when you type following
$ man ls
$ info bash
NOTE: In MS-DOS, you get help by using /? clue or by typing help command as
C:\> dir /?
C:\> date /?
C:\> help time
C:\> help date
C:\> help
Linux Command
For this Purpose
Use this Command Syntax
Example ( In front of $
Prompt)

To see date
date
$ date
To see who's using
system.

who
$ who
Print working directory
pwd
$ pwd
List name of files in
current directory

ls or dirs
$ ls
To create text file
NOTE: Press and hold
CTRL key and press D to
stop or to end file
(CTRL+D)

cat > { file name }
$ cat > myfile
type your text
when done press
^D

To text see files
cat {file name }
$ cat myfile
To display file one full
screen at a time

more {file name }
$ more myfile
To move or rename
file/directory
mv {file1} {file2}
$ mv sales
sales.99
To create multiple file
copies with various link.
After this both oldfile
newfile refers to same
name

ln {oldfile} {newfile}
$ ln Page1 Book1
To remove file
rm file1
$ rm myfile
Linux Shell Script Tutorial