Friday, 5 August 2011

Why Command Line arguments required


  1. Telling the command/utility which option to use.
  2. Informing the utility/command which file or group of files to process (reading/writing of files). 
To run two command with one command line.
Syntax:
command1;command2

$ date;who

2 comments:

  1. To combine two or more command line argument, use pipe characters ( |, >, < )

    like

    $ps -aef | grep

    ReplyDelete
  2. Pipe character is used when output of first command will work as input of second command.
    For eg:-
    $ps -ef | grep load

    ps -ef fetch all the process running on ur machine,and grep filter the processes from the result,which is started from load.

    ReplyDelete