Instructions on how to turn in Project #1

Due date: Thursday 4/22/2004 by 22:00 (10:00pm)

We will be using electronic submission for this project. You may have used electronic submit in some of your previous classes. In order to use it, you will have to copy the files to your seas account. If you do not have a seas account, and you are an engineering student, you can can apply for one here. If you are not an engineering student, you can apply at the SEASnet Office. Account requests take 1 business day to processes.

From your SEASnet account, run submit cs111 <file1> <file2> <file3>. You can not submit the same file twice. If you need to resubmit, append -number to the file. For example: to resubmit the README file, submit README-1; to resubmit it again submit README-2.

Do not submit MS Word files. (or KWord, or Openoffice, or anything other then plain text)

You will have to submit the following:

(a) Copies of your C program or programs (sufficiently -- but not excessively -- documented source code) and header files (if any).

(b) Both the README file (last minute info, what works and what doesn't work) and the lab report-manual file (do not combine the two files). The report-manual describes to someone that does not know anything about the project what the project does, and how it can be compiled and executed. Maximum size for the README file: 300 words. Maximum size for the report: 500 words. Also you must submit a journal (log) with information about who did what and how long it took.

(c) Copies of files created in the test cases (findout.txt, /tmp/sorted.txt, etc.), after you are done with testing.

(d) A copy of the script file that demonstrates the successful clean compilation and running of the program using at least the test cases below.  When the script command is running do not edit files with vi or other editors because it will mess up the script file. Once you have the final version of your executable, then you create the script of the run with the test cases. 

To produce a script file execute the command:

script -a script_file_name.txt [Return]

script_file_name.txt above is the name you'll choose for your script file. Type exit to exit the script when done. Do not use extension .c for the script files! You may overwrite your C programs and lose them forever!

(e) A file named partners.txt with your name(s) and the name of your TA !!! Don't forget this!

 

Testing Cases

In the testing suite, you will have the following files, and # is the prompt of your shell program:

The testing suite consists of the following cases that should be executed in the order below and recorded in the script:

Part A:

# carriage-return
# ls
# ls -lt
# ls -l /tmp
# cd /usr

# pwd
# /bin/ls
# cd back to your working directory

# pwd
# find /bin -name ls -print
# who
# Ls -L
# cd

# pwd
# more /etc/fstab
# cat /etc/fstab
# cd
# pwd
# ps
# exit (your shell terminates)

Part B:
(restart your shell program here)

# find /bin
# find /bin > findout.txt
# sort < findout.txt
# ls & wc
# cd /lib

# pwd
# ls -lR && cal
# xyz && cal
# ls -lR || cal
# true || cal
# ls ; cal
# xyz ; cal
 

Part C:

# find /lib > /tmp/find.txt
# sort < /tmp/find.txt > /tmp/sorted.txt && ls -l /tmp/sorted.txt
# cal 1 2004 && cal 2 2004 && cal 3 2004 && cal 4 2004 || cal 5 2004 && cal 6 2004 || ls ; true || cal 7 2004
# find /lib > /tmp/findout.txt &
# find /lib &
# ls
# ||
# (execute your shell from your shell here, i.e. as a local executable)
# ps
# ls && ||
# ls &&&
#
 
# exit

# ls -l
# exit