Skip to content

Commit 947b718

Browse files
committed
Add "requirements.txt" file.
1 parent 98b2471 commit 947b718

File tree

2 files changed

+99
-8
lines changed

2 files changed

+99
-8
lines changed

requirements.txt

Lines changed: 70 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,70 @@
1+
alabaster==0.7.12
2+
atomicwrites==1.3.0
3+
attrs==19.2.0
4+
babel==2.7.0
5+
biblib-simple==0.1.1
6+
bleach==3.1.0
7+
certifi==2019.9.11
8+
chardet==3.0.4
9+
colorama==0.4.1; sys_platform == "win32"
10+
colour-science==0.3.13
11+
coverage==4.5.4
12+
coveralls==1.8.2
13+
docopt==0.6.2
14+
docutils==0.15.2
15+
entrypoints==0.3
16+
flake8==3.7.8
17+
idna==2.8
18+
imageio==2.5.0
19+
imagesize==1.1.0
20+
importlib-metadata==0.23; python_version < "3.8"
21+
invoke==1.3.0
22+
jinja2==2.10.3
23+
latexcodec==1.0.7
24+
markupsafe==1.1.1
25+
mccabe==0.6.1
26+
mock==3.0.5
27+
more-itertools==7.2.0
28+
nose==1.3.7
29+
numpy==1.17.2
30+
opencv-python==4.1.1.26
31+
oset==0.1.3
32+
packaging==19.2
33+
pathlib2==2.3.5; python_version < "3.6"
34+
pillow==6.2.0
35+
pkginfo==1.5.0.1
36+
pluggy==0.13.0
37+
py==1.8.0
38+
pybtex==0.22.2
39+
pybtex-docutils==0.2.1
40+
pycodestyle==2.5.0
41+
pyflakes==2.1.1
42+
pygments==2.4.2
43+
pyparsing==2.4.2
44+
pytest==5.2.0
45+
pytz==2019.2
46+
pyyaml==5.1.2
47+
readme-renderer==24.0
48+
requests==2.22.0
49+
requests-toolbelt==0.9.1
50+
restructuredtext-lint==1.3.0
51+
scipy==1.3.1
52+
six==1.12.0
53+
snowballstemmer==2.0.0
54+
sphinx==2.2.0
55+
sphinx-rtd-theme==0.4.3
56+
sphinxcontrib-applehelp==1.0.1
57+
sphinxcontrib-bibtex==1.0.0
58+
sphinxcontrib-devhelp==1.0.1
59+
sphinxcontrib-htmlhelp==1.0.2
60+
sphinxcontrib-jsmath==1.0.1
61+
sphinxcontrib-qthelp==1.0.2
62+
sphinxcontrib-serializinghtml==1.1.3
63+
toml==0.10.0
64+
tqdm==4.36.1
65+
twine==1.15.0
66+
urllib3==1.25.6
67+
wcwidth==0.1.7
68+
webencodings==0.5.1
69+
yapf==0.23.0
70+
zipp==0.6.0; python_version < "3.8"

tasks.py

Lines changed: 29 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,8 @@
2828
__all__ = [
2929
'APPLICATION_NAME', 'APPLICATION_VERSION', 'PYTHON_PACKAGE_NAME',
3030
'PYPI_PACKAGE_NAME', 'BIBLIOGRAPHY_NAME', 'clean', 'formatting', 'tests',
31-
'quality', 'examples', 'docs', 'todo', 'preflight', 'build', 'virtualise',
32-
'tag', 'release', 'sha256'
31+
'quality', 'examples', 'preflight', 'docs', 'todo', 'requirements',
32+
'build', 'virtualise', 'tag', 'release', 'sha256'
3333
]
3434

3535
APPLICATION_NAME = colour_checker_detection.__application_name__
@@ -212,6 +212,26 @@ def examples(ctx):
212212
ctx.run('python {0}'.format(os.path.join(root, filename)))
213213

214214

215+
@task(formatting, tests, quality, examples)
216+
def preflight(ctx):
217+
"""
218+
Performs the preflight tasks, i.e., *formatting*, *tests*, *quality*, and
219+
*examples*.
220+
221+
Parameters
222+
----------
223+
ctx : invoke.context.Context
224+
Context.
225+
226+
Returns
227+
-------
228+
bool
229+
Task success.
230+
"""
231+
232+
message_box('Finishing "Preflight"...')
233+
234+
215235
@task
216236
def docs(ctx, html=True, pdf=True):
217237
"""
@@ -265,11 +285,10 @@ def todo(ctx):
265285
ctx.run('./export_todo.py')
266286

267287

268-
@task(formatting, tests, quality, examples)
269-
def preflight(ctx):
288+
@task
289+
def requirements(ctx):
270290
"""
271-
Performs the preflight tasks, i.e., *formatting*, *tests*, *quality*, and
272-
*examples*.
291+
Export the *requirements.txt* file.
273292
274293
Parameters
275294
----------
@@ -282,10 +301,12 @@ def preflight(ctx):
282301
Task success.
283302
"""
284303

285-
message_box('Finishing "Preflight"...')
304+
message_box('Exporting "requirements.txt" file...')
305+
ctx.run('poetry export -f requirements.txt --without-hashes --dev '
306+
'-o requirements.txt')
286307

287308

288-
@task(preflight, todo, docs)
309+
@task(preflight, docs, todo, requirements)
289310
def build(ctx):
290311
"""
291312
Builds the project and runs dependency tasks, i.e., *docs*, *todo*, and

0 commit comments

Comments
 (0)