tar
and
gzip
to create a compressed "tape" archive file of your project
directory:
~/cpsc215/asg1
directory:
[andrewd@hook] ~/cpsc215/asg1 > ls Makefile a.out* main.o sample.out stk.h README main.c out stk.c stk.o [andrewd@hook] ~/cpsc215/asg1 >
make clean
to clean up all the *.o
and
executable files (to reduce space):
[andrewd@hook] ~/cpsc215/asg1 > make clean rm *.o a.out [andrewd@hook] ~/cpsc215/asg1 >
[andrewd@hook] ~/cpsc215/asg1 > cd ../ [andrewd@hook] ~/cpsc215 >
tar cvf <file.tar> <directory>where
<file.tar>
is the tar file being
created, and <directory>
is the directory
which will get archived (stuffed) into the single tar file:
[andrewd@hook] ~/cpsc215 > tar cvf asg1.tar asg1 a asg1/Makefile 1 block a asg1/README 1 block a asg1/main.c 2 blocks a asg1/out 2 blocks a asg1/sample.out 2 blocks a asg1/stk.c 3 blocks a asg1/stk.h 1 block [andrewd@hook] ~/cpsc215 >You'll see a list of
a <directory/file>
additions being assembled into the tar file. You should now
have the file <file.tar>
.
- Compress the tar file using
gzip
:
[andrewd@hook] ~/cpsc215 > gzip asg1.tar
[andrewd@hook] ~/cpsc215 >
You'll now see the file <file.tar.gz>
.
This is the file you want to submit electronically.