Click pkg not getting added to requirements
leg100 opened this issue · 2 comments
leg100 commented
- Cookiecutter version used, if any: 1.6.0
- Python version, if any: 3.6.5
- Operating System: Ubuntu 16.04
Description
Click is not getting added to requirements_dev.txt, even though at the prompt I requested it.
What I Did
$ cookiecutter https://github.com/audreyr/cookiecutter-pypackage.git
You've downloaded /home/louis/.cookiecutters/cookiecutter-pypackage before. Is it okay to delete and re-download it? [yes]: yes
<-- snip --->
Select command_line_interface:
1 - Click
2 - No command-line interface
Choose from 1, 2 [1]:
<-- snip --->
$ cat requirements.txt
pip==9.0.1
bumpversion==0.5.3
wheel==0.30.0
watchdog==0.8.3
flake8==3.5.0
tox==2.9.1
coverage==4.5.1
Sphinx==1.7.1
twine==1.10.0
pytest==3.4.2
pytest-runner==2.11.1
I suspect the cause is that the jinja template is checking if command_line_interface
is equal to y
, whereas it should check if it is equal to Click
:
{{cookiecutter.project_slug}}/requirements_dev.txt
10:{% if cookiecutter.command_line_interface == 'y' -%}
kpfleming commented
Click
is included in the requirements list in setup.py
, so it will be installed when the package is installed using setuptools. It's not a development requirement, it's an actual requirement of the new application (at runtime), so it does not need to be listed in requirements_dev.txt
.