# merging parts



## namenotfound (Apr 30, 2005)

I have two part files (.001 & .002), and I want to merge them together and change the file extension to .zip

I forgot what the terminal command was for this, I just remember it had '>' symbol in it. Can you tell me what the command is?


----------



## lotuseclat79 (Sep 12, 2003)

Hi namenotfound,

Try: $ cat .001 .002 > merge
assuming the file merge does not exist in the current directory.

A .zip file extension implies a compressed file that has been zipped with zip, so if .001 and .002 are not compressed, you can then issue the command:
$ zip merge
to create merge.zip

If you issue the command:
$ file .001 .002
if the files are already compressed by zip, the output will tell you the files are compressed, and if so, you can then issue the command:
$ cate .001 .002 > merge.zip

Upon doing so, you should test whether you can do:
$ unzip merge.zip
however, you got to that point.

-- Tom

P.S. Another way to do it would be:
$ cat .002 >> .001
in order to append .002 to the end of .001, assuming they are both in the same uncompressed format, then
$ zip .001
in order to produce the file .001.zip


----------

