-
Notifications
You must be signed in to change notification settings - Fork 24
/
setup.py
27 lines (17 loc) · 631 Bytes
/
setup.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
"""This module contains the packaging routine for the ``scrapy-algolia-exporter`` package"""
from setuptools import setup, find_packages
from pip.download import PipSession
from pip.req import parse_requirements
def get_requirements(source):
"""Get the requirements from the given ``source``
Parameters
----------
source: str
The filename containing the requirements
"""
install_reqs = parse_requirements(filename=source, session=PipSession())
return [str(ir.req) for ir in install_reqs]
setup(
packages=find_packages(),
install_requires=get_requirements('requirements.txt')
)