Permalink
Browse files

Support xz decompression on CentOS with older version of tar

  • Loading branch information...
1 parent 2451fb0 commit ba94134d68863187c06f2ef0c69eb1cca0a9804f @chapmanb committed Apr 10, 2011
Showing with 7 additions and 2 deletions.
  1. +2 −0 config/packages-yum.yaml
  2. +2 −0 config/packages.yaml
  3. +1 −1 data_fabfile.py
  4. +2 −1 utils/s3_multipart_upload.py
View
2 config/packages-yum.yaml
@@ -39,6 +39,8 @@ programming:
- zziplib-devel
- bzip2
- bzip2-devel
+ - xz
+ - xz-devel
- gtk2
- gtk2-devel
- ncurses-devel
View
2 config/packages.yaml
@@ -65,6 +65,8 @@ programming:
- libc6-dev
- libzip-dev
- libbz2-dev
+ - xz-utils
+ - liblzma-dev
- libgtk2.0-dev
- libncurses5-dev
- zlib1g-dev
View
2 data_fabfile.py
@@ -606,7 +606,7 @@ def _download_genomes(genomes, genome_indexes):
if not exists(idx):
url = "https://s3.amazonaws.com/biodata/genomes/%s-%s.tar.xz" % (gid, idx)
run("wget --no-check-certificate %s" % url)
- run("tar -xJvpf %s" % os.path.basename(url))
+ run("xz -dc %s | tar -xvpf -" % os.path.basename(url))
run("rm -f %s" % os.path.basename(url))
ref_file = os.path.join(org_dir, "seq", "%s.fa" % gid)
assert exists(ref_file), ref_file
View
3 utils/s3_multipart_upload.py
@@ -97,7 +97,8 @@ def split_file(in_file, mb_size, split_num=5):
mp = bucket.initiate_multipart_upload(s3_key_name, reduced_redundancy=use_rr)
with multimap(cores) as pmap:
- for _ in pmap(transfer_part, ((mp.id, mp.key_name, mp.bucket_name, i, part) for (i, part) in
+ for _ in pmap(transfer_part, ((mp.id, mp.key_name, mp.bucket_name, i, part)
+ for (i, part) in
enumerate(split_file(tarball, mb_size, cores)))):
pass
mp.complete_upload()

0 comments on commit ba94134

Please sign in to comment.