Archive, compress and uncompress files

zip

zip is a compression and file packaging utility

Warning

zip dir.zip dir produce an empty zip file

exercice:

create a compress archive of all files in the Sequence/Proteique dir

unzip

unzip - list, test and extract compressed files in a ZIP archive

exercice:

list, test and uncompress the zip archive proteique.zip that you did.

gzip

gzip compress files (does not make an archive!)

exercise:

execute gzip Sequence/Proteique/ *
what is the difference with zip ?

gunzip

exercise:

uncompress the files in Sequence/Proteique/

bzip2

create archive

GNU ‘tar’ saves many files together into a single tape or disk archive.

Warning

This archive is not compress

create archive

exercise:

create and compress an archive

create and compress an archive

exercise:

list the content of an archive

To know what an archive contains use the -t option.

tar -tzf archive.tar.gz
tar -tjf archive.tar.bz2

tar -tzf toto.tar.gz
Nucleique/
Nucleique/qn1.gb
Nucleique/qr.fasta
Nucleique/collection_of_colstridium_genomesFASTA.txt
...

uncompress and restore an archive

To extract an archive use the -x option. To uncompress an archive use -z or -j option for gzip or bzip2 respectively.

tar -xzf archive.tar.gz
tar -xjf archive.tar.bz2

by default the extract is been wher the command is run we can change this using -C dir option.

tar -xjf archive.tar.bz2 -C Foobar

Warning

the dir must exists

send an archive by mail

F*EX is the dl service at pasteur

  1. register fexsend -I

    fexsend -I
    F*EX server URL: http://dl.pasteur.fr/
    proxy address (hostname:port or empty if none):
    Your e-mail address as registered at http://dl.pasteur.fr/: nimort.naoik@pasteur.fr
    Your auth-ID for nimort.naoik@pasteur.fr at http://dl.pasteur.fr/: pick_an_id
    data written to /pasteur/homes/nnaoik/.fex/id
    
  2. fexsend file recipient@domain.fr

send an archive by mail

exercise:

  1. for those who have not a fex account go on http://dl.pasteur.fr/ and request an account
  2. log on central-bio.pasteur.fr
  3. send you one of the archive you did using F*EX

(documentaion: https://projets.pasteur.fr/projects/fex/wiki)