Assignment: File Festival
The purpose of this assignment is to establish, refine, and demonstrate your ability to manage directories and files.
The AssignmentFor security and administrative reasons, you must use the Unix account supplied to you by the University to prepare and email your assignment--failure to do so will result in your assignment not being graded.
In this assignment, you will create a file and directory structure, record it using a listing command and output redirection, and then change the structure and record its change with another listing command.
- In your home directory, create a directory called filefest.
Inside this directory filefest, create
set of directories and files as shown in the following diagram.
Use the Unix command mkdir
to create a directory.
Use whatever means you would
like to make the files, such as output redirection or the
Unix touch command.
The contents of the files can be anything (or empty),
but they must be plain text
files, and you must use the exact names as shown in the diagram.
In this diagram, there are three directories under filefest: pigstage, northgate, and rockstage. In pigstage, there are two files: kelly and nicole. In northgate, there is one file: john. In rockstage, there are two files--deni and kyle--and one directory, bleachers. In bleachers, there is one file, kevin.
- In the filefest directory, look at
the directory structure you have created
by using the Unix list command
Here is an example that I did and how it looked. I did a pwd command at the start to show the present working directory when I did the ls -lR command.
$ pwd /users/aux/adjunct/johnd/filefest $ ls -lR total 3 drwx------ 2 johnd 512 Mar 6 06:34 northgate drwx------ 2 johnd 512 Mar 6 06:33 pigstage drwx------ 3 johnd 512 Mar 6 06:34 rockstage northgate: total 0 -rw------- 1 johnd 0 Mar 6 06:34 john pigstage: total 0 -rw------- 1 johnd 0 Mar 6 06:33 kelly -rw------- 1 johnd 0 Mar 6 06:33 nicole rockstage: total 1 drwx------ 2 johnd 512 Mar 6 06:34 bleachers -rw------- 1 johnd 0 Mar 6 06:34 deni -rw------- 1 johnd 0 Mar 6 06:34 kyle rockstage/bleachers: total 0 -rw------- 1 johnd 0 Mar 6 06:34 kevin $
- Still in the filefest directory, do the ls -lR command again, but this time redirect the output of this ls -lR command to a file called listing.
- Now move all the files in the directories pigstage (kelly and nicole), rockstage (deni and kyle), and bleachers (kevin) to northgate.
Now delete the
directories pigstage, rockstage, and bleachers.
Once you have moved the files and deleted the directories, you would have this structure:
- Still in the filefest directory, use the ls -lR again to look at the new file structure you have.
- Still in the filefest directory, append the output of this ls -lR command to the file listing.
- Your assignment is to email the contents of the file listing that you created. This will show your directory and file structure "before" and "after" moving the files and deleting the directories.
Remember, check for a receipt from me to make sure that I received your assignment before you consider the assignment done--remember "It's not complete until you get your receipt!"
GradingYour assignment will be graded according to criteria I set up for this tutorial.
For the 60% content score,
- Your "before" part of listing is 30%
- +6% four directories inside filefest with correct names (pigstage, northgate, rockstage, bleachers)
- +6% six files with correct names (kelly, nicole, john, kyle, deni, kevin)
- +6% directory structure as specified (including bleachers as subdirectory of rockstage)
- +6% files in correct directories
- +6% listing is result of ls -lR and shows only standard output, not the command
- Your "after" part of listing is 30%
- +10% just one directory left (northgate) inside filefest
- +10% six files in correct place; plus listing file in correct place
- +10% listing is result of ls -lR and shows only standard output, not the command
Turning in Your Assignment
Your assignment is due by the time listed on the syllabus. Use these procedures for turning in your assignment. Your assignment will be graded according to criteria I set up for this tutorial.