Ferreira Logo

Ferreira's Gentle Sailing Web Site

BCC Logo Home CIS132 CIS134 CIS158 CIT150 CIT250 CIT251

Help

Class Policy - Shell Scripts

Policy
  1. Scripts are to be done and stored on CISWEB.

  2. All shell scripts begin with a series of comments to document the script. These comments must include in order the following:
    • Name of the script.
    • Name of the author.
    • The date the script was written.
    • The assignment number.
    • A description of the what the script is designed to do.

  3. Each section of the program as well as any significant information is to be commented.

Example
     #                             myfile
     #                               by Jane Smith
     #                                  March 6, 2012
     #
     #   Assignment: P99
     #   Due Date:   March 8, 2012
     #
     #   Script will display the file myBook and then count the number of 
     #   lines and words
     #
     #   Display the file one screen at a time

     cat myBook | more

     #   display the number for lines and words

     echo Number of lines:
     wc -l < myfBook
     echo Number of words:
     wc -w < myfBook