spack/var/spack/repos/builtin/packages/py-mixedhtseq/package.py
Todd Gamblin 24c01d57cf
imports: sort imports everywhere in Spack (#24695)
* fix remaining flake8 errors

* imports: sort imports everywhere in Spack

We enabled import order checking in #23947, but fixing things manually drives
people crazy. This used `spack style --fix --all` from #24071 to automatically
sort everything in Spack so PR submitters won't have to deal with it.

This should go in after #24071, as it assumes we're using `isort`, not
`flake8-import-order` to order things. `isort` seems to be more flexible and
allows `llnl` mports to be in their own group before `spack` ones, so this
seems like a good switch.
2021-07-08 22:12:30 +00:00

41 lines
1.3 KiB
Python

# Copyright 2013-2021 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
import glob
from spack import *
class PyMixedhtseq(PythonPackage):
"""HTSeq for mixed single and paired end reads"""
homepage = "https://github.com/schae234/MixedHTSeq"
url = "https://github.com/schae234/MixedHTSeq/archive/v0.1.0.tar.gz"
version('0.1.0', sha256='234689c8743ae2ba7ad13bc1809a5248184a4b8d16112d5413e09164ab67e157')
depends_on('python@2.5:2.8', type=('build', 'run'))
depends_on('py-numpy', type=('build', 'run'))
depends_on('py-htseq', type=('build', 'run'))
depends_on('py-ipython', type=('build', 'run'))
depends_on('py-pandas', type=('build', 'run'))
depends_on('py-setuptools', type='build')
@run_after('install')
def install_scripts(self):
shebang = '#!{0}\n'.format(self.spec['python'].command)
for fname in glob.glob('scripts/*.py'):
filter_file('^#!.*', '', fname)
with open(fname, 'r') as orig:
fdata = orig.read()
with open(fname, 'w') as new:
new.write(shebang + fdata)
set_executable(fname)
mkdirp(self.prefix.bin)
install_tree('scripts', self.prefix.bin)