#!/bin/bash ######################################## # # An example to show reading from a file # and some command line variables # # Author: Bill Kraynek # ######################################## # The -e option of the echo command allows special chars # like \b \c \n etc to be interpreted echo -e "Enter a line: \c" read line echo "You entered: $line" echo -e "Enter another line: \c" read word1 word2 word3 echo "The first word was: $word1" echo "The second word was: $word2" echo "The rest of the line was: $word3" echo "The command name is: $0." echo "The number of command line arguments is $#." echo "The value of the arguments are: $1 $2 $3 $4" echo "Another way to display the arguments: $@." exit 0