Mercurial > repos > da-intersect > test_ap11
view tar.py @ 10:27fd6bbf6b2f
Uploaded
author | da-intersect |
---|---|
date | Thu, 11 Apr 2013 01:44:03 -0400 |
parents | |
children | 3f8a5e98cf36 |
line wrap: on
line source
from galaxy.datatypes.metadata import MetadataElement from galaxy.datatypes.binary import Binary from galaxy.datatypes import metadata from galaxy.datatypes.sniff import * from galaxy import eggs import pkg_resources pkg_resources.require( "bx-python" ) from urllib import urlencode, quote_plus import zipfile, gzip import os, subprocess, tempfile, tarfile import struct class Tar( Binary ): """Class describing a BAM binary file""" file_ext = "tar" def sniff( self, filename ): try: if tarfile.is_tarfile(filename): return True except: return False