-
Notifications
You must be signed in to change notification settings - Fork 148
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
CHORE: consolidate requirements to setup.py #105
base: master
Are you sure you want to change the base?
Changes from 1 commit
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,18 +3,12 @@ | |
We need to clone the project and prepare the dev environment: | ||
|
||
```bash | ||
$ git clone https://github.com/manrajgrover/halo.git // or using ssh: [email protected]:manrajgrover/halo.git | ||
$ git clone https://github.com/manrajgrover/halo.git # or using ssh: [email protected]:manrajgrover/halo.git | ||
$ cd halo | ||
$ pip install -e . | ||
$ pip install -e requirements-dev.txt | ||
``` | ||
|
||
This will install all requirements to use `halo`. You may want to create a virtual environment specifically for this. | ||
|
||
To install development dependencies, run: | ||
|
||
```bash | ||
$ pip install -r requirements-dev.txt | ||
``` | ||
This will install all requirements to use and develop `halo`. You may want to create a virtual environment specifically for this. | ||
|
||
#### Testing | ||
Before submitting a pull request, make sure the code passes all the tests and is clean of lint errors: | ||
|
@@ -27,15 +21,15 @@ To run tests for specific environment, run: | |
|
||
1. For Python 2.7: | ||
|
||
```bash | ||
$ tox -e py27 | ||
``` | ||
```bash | ||
$ tox -e py27 | ||
``` | ||
|
||
2. For Python 3.6: | ||
|
||
```bash | ||
$ tox -e py36 | ||
``` | ||
```bash | ||
$ tox -e py36 | ||
``` | ||
|
||
For checking lint issues: | ||
|
||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1 @@ | ||
coverage==4.4.1 | ||
nose==1.3.7 | ||
pylint==1.7.2 | ||
tox==2.8.2 | ||
--editable .[dev] | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Same here, is this file needed? |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1 @@ | ||
backports.shutil_get_terminal_size==1.0.0;python_version < '3.3' | ||
log_symbols==0.0.11 | ||
spinners==0.0.23 | ||
cursor==1.2.0 | ||
termcolor==1.1.0 | ||
colorama==0.3.9 | ||
six==1.11.0 | ||
--editable . | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I don't think we need this file now There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,10 @@ | ||
from setuptools import setup, find_packages # pylint: disable=no-name-in-module,import-error | ||
|
||
|
||
def dependencies(file): | ||
with open(file) as f: | ||
return f.read().splitlines() | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. btw, this is equivalent to |
||
|
||
|
||
setup( | ||
name='halo', | ||
packages=find_packages(exclude=('tests', 'examples')), | ||
include_package_data=True, | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @theY4Kman What does this line do? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. lol, I'm not sure, tbh. The line was there previously, just below the reqs. I thought it looked out of place, so I moved it to the other line that said "package" :P There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah, just noticed! I should check but I remember stumbling upon an error before adding it. |
||
version='0.0.18', | ||
license='MIT', | ||
description='Beautiful terminal spinners in Python', | ||
|
@@ -17,26 +13,44 @@ def dependencies(file): | |
author_email='[email protected]', | ||
url='https://github.com/manrajgrover/halo', | ||
keywords=[ | ||
"console", | ||
"loading", | ||
"indicator", | ||
"progress", | ||
"cli", | ||
"spinner", | ||
"spinners", | ||
"terminal", | ||
"term", | ||
"busy", | ||
"wait", | ||
"idle" | ||
'console', | ||
'loading', | ||
'indicator', | ||
'progress', | ||
'cli', | ||
'spinner', | ||
'spinners', | ||
'terminal', | ||
'term', | ||
'busy', | ||
'wait', | ||
'idle', | ||
], | ||
install_requires=[ | ||
'backports.shutil_get_terminal_size==1.0.0;python_version < "3.3"', | ||
'log_symbols==0.0.11', | ||
'spinners==0.0.23', | ||
'cursor==1.2.0', | ||
'termcolor==1.1.0', | ||
'colorama==0.3.9', | ||
'six==1.11.0', | ||
Comment on lines
+31
to
+36
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Since halo is a library intended to be used by other scripts, it should be liberal in its requirements. |
||
], | ||
install_requires=dependencies('requirements.txt'), | ||
tests_require=dependencies('requirements-dev.txt'), | ||
include_package_data=True, | ||
extras_require={ | ||
'ipython': [ | ||
'IPython==5.7.0', | ||
'ipywidgets==7.1.0', | ||
] | ||
} | ||
], | ||
'test': [ | ||
'coverage==4.4.1', | ||
'nose==1.3.7', | ||
'pylint==1.7.2', | ||
'tox==2.8.2', | ||
], | ||
'dev': [ | ||
'halo[test,ipython]', | ||
], | ||
}, | ||
tests_require=[ | ||
'halo[test]', | ||
], | ||
) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We can do
pip install -e .[dev]
here?