Skip to content

Commit

Permalink
add requirements files
Browse files Browse the repository at this point in the history
  • Loading branch information
ameily committed Aug 24, 2018
1 parent 6fd94ca commit 42ce354
Show file tree
Hide file tree
Showing 4 changed files with 28 additions and 8 deletions.
5 changes: 5 additions & 0 deletions requirements/requirements-dev-py33.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
pytest==3.2.5
isort==4.2.14
pylint==1.7.6
pycodestyle==2.4.0
wheel==0.29.0
3 changes: 3 additions & 0 deletions requirements/requirements-dev.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
pytest>=3.6.2
pylint>=1.9.2
pycodestyle==2.4.0
2 changes: 2 additions & 0 deletions requirements/requirements.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
chardet>=2.0.1
pyreadline>=2.1;platform_system=="Windows"
26 changes: 18 additions & 8 deletions setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,32 +15,42 @@
# OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
#

import platform
# import platform
import os
import sys
from setuptools import setup
import pypsi


def read(path):
return open(path, 'r').read()
def load_requirements(filename):
path = os.path.join(os.path.dirname(__file__), 'requirements', filename)
return [line for line in open(path, 'r').readlines() if line.strip() and not line.startswith('#')]


install_requires = ['chardet>=2.0.1']
if platform.system() == 'Windows':
install_requires.append('pyreadline')
requirements = load_requirements('requirements.txt')
if sys.version_info[:2] == (3, 3):
dev_requirements = load_requirements('requirements-dev-py33.txt')
else:
dev_requirements = load_requirements('requirements-dev.txt')


print(requirements)

setup(
name='pypsi',
version=pypsi.__release__,
license='ISC',
description='Python Pluggable Shell Interface',
long_description=read("README.rst"),
long_description=open("README.rst", 'r').read(),
author='Adam Meily',
author_email='[email protected]',
url='https://github.com/ameily/pypsi',
download_url='https://pypi.python.org/pypi/pypsi',
packages=['pypsi', 'pypsi.commands', 'pypsi.plugins', 'pypsi.os'],
install_requires=install_requires,
install_requires=requirements,
extras_require={
'dev': dev_requirements
},
keywords=[
'cli', 'command line', 'command line interface', 'shell', 'terminal',
'console', 'term', 'command prompt',
Expand Down

0 comments on commit 42ce354

Please sign in to comment.