easyblock = "PythonPackage"

name = 'csvkit'
version = '0.9.1'

homepage = 'https://github.com/wireservice/csvkit'
description = """csvkit is a suite of command-line tools for converting to and working with CSV,
 the king of tabular file formats."""

toolchain = {'name': 'foss', 'version': '2015b'}

source_urls = [PYPI_SOURCE]
sources = [SOURCELOWER_TAR_GZ]

python = 'Python'
pyver = '2.7.10'
pyshortver = '.'.join(pyver.split('.')[:2])

versionsuffix = "-%s-%s" % (python, pyver)

dependencies = [
    (python, pyver),
]

postinstallcmds = ["chmod -R +r %(installdir)s/lib/"]

sanity_check_paths = {
    'files': ['bin/in2csv', 'bin/sql2csv', 'bin/csvclean', 'bin/csvcut', 'bin/csvgrep', 'bin/csvjoin',
              'bin/csvsort', 'bin/csvstack', 'bin/csvformat', 'bin/csvjson', 'bin/csvlook', 'bin/csvpy',
              'bin/csvsql', 'bin/csvstat'],
    'dirs': [],
}

sanity_check_commands = [('csvlook', '-h')]

moduleclass = 'tools'
