Skip to content

Commit

Permalink
Merge pull request #127 from cgat-developers/AC-bugs
Browse files Browse the repository at this point in the history
reversted setup.py changes
  • Loading branch information
Acribbs committed Apr 5, 2024
2 parents 3f43049 + f3b1c75 commit b7b6936
Show file tree
Hide file tree
Showing 2 changed files with 32 additions and 0 deletions.
Empty file added requires.txt
Empty file.
32 changes: 32 additions & 0 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -137,6 +137,37 @@ def is_exe(fpath):
HTTPS_REQUIREMENT = re.compile(
r'^-e (?P<link>.*).+#(?P<package>.+)-(?P<version>\d(?:\.\d)*)$')
install_requires = []
dependency_links = []

for requirement in (
l.strip() for l in open('requires.txt') if not l.startswith("#")):
match = REPO_REQUIREMENT.match(requirement)
if match:
assert which(match.group('vcs')) is not None, \
("VCS '%(vcs)s' must be installed in order to "
"install %(link)s" % match.groupdict())
install_requires.append("%(package)s==%(version)s" % match.groupdict())
dependency_links.append(match.group('link'))
continue

if requirement.startswith("https"):
install_requires.append(requirement)
continue

match = HTTPS_REQUIREMENT.match(requirement)
if match:
install_requires.append("%(package)s>=%(version)s" % match.groupdict())
dependency_links.append(match.group('link'))
continue

install_requires.append(requirement)

if major == 2:
install_requires.extend(['web.py>=0.37',
'xlwt>=0.7.4',
'matplotlib-venn>=0.5'])
elif major == 3:
pass

cgat_packages = find_packages()
cgat_package_dirs = {'cgat': 'cgat'}
Expand Down Expand Up @@ -286,6 +317,7 @@ def is_exe(fpath):
},
# dependencies
install_requires=install_requires,
dependency_links=dependency_links,
# extension modules
ext_modules=extensions,
cmdclass={'build_ext': build_ext},
Expand Down

0 comments on commit b7b6936

Please sign in to comment.