Home > Blockchain >  Cat files except one
Cat files except one

Time:11-04

I have split a large file into many splits, then I created an md5sum for all the files. My question, how can i merge the files except the md5 file? Here is an example:

  /home/files/file.iso.00
  /home/files/file.iso.01
  ..
  /home/files/file.iso.52
  /home/files/file.iso.md5

I tried the following but it didn't work:

cat file.iso.[[:digit:]] >> file.iso

Many thanks in advance.

CodePudding user response:

As you are the one having created the MD5 checksum file, why did you call it /home/files/file.iso.md5?
If you call it /home/files/file.md5 (without the iso part), you won't have a problem anymore.

CodePudding user response:

Found the answer:

find . -regex '.*\.[0-9][0-9]' -exec cat {} \; >> file.iso

I don't believe there is a way to filter files using cat. But if you find the files then cat them, it should work just fine.

  • Related