Skip to content

Commit 0c9e26a

Browse files
committed
fix setup requirements
1 parent 46b395f commit 0c9e26a

File tree

2 files changed

+12
-9
lines changed

2 files changed

+12
-9
lines changed

requirements.txt

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,2 +1 @@
1-
intersystems_irispython
2-
-e git+https://github.com/intersystems-community/iris-driver-distribution/raw/main/intersystems_irispython-3.2.0-py3-none-any.whl
1+
https://github.com/intersystems-community/iris-driver-distribution/raw/main/intersystems_irispython-3.2.0-py3-none-any.whl

setup.py

Lines changed: 11 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,17 @@
1-
import re
21
from setuptools import setup
2+
import os
3+
4+
thelibFolder = os.path.dirname(os.path.realpath(__file__))
5+
requirementPath = thelibFolder + '/requirements.txt'
36

47
requirements, dependency_links = [], []
5-
with open('requirements.txt') as f:
6-
for line in f.read().splitlines():
7-
if line.startswith('-e git+'):
8-
dependency_links.append(line.replace('-e git+', ''))
9-
else:
10-
requirements.append(line)
8+
if os.path.isfile(requirementPath):
9+
with open('./requirements.txt') as f:
10+
for line in f.read().splitlines():
11+
if line.startswith('http'):
12+
dependency_links.append(line)
13+
else:
14+
requirements.append(line)
1115

1216
setup(install_requires=requirements,
1317
dependency_links=dependency_links)

0 commit comments

Comments
 (0)