Register
Login
Resources
Docs Blog Datasets Glossary Case Studies Tutorials & Webinars
Product
Data Engine LLMs Platform Enterprise
Pricing Explore
Connect to our Discord channel

Makefile 2.2 KB

You have to be logged in to leave a comment. Sign In
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
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
  1. .PHONY: clean clean-test clean-pyc clean-build docs help
  2. .DEFAULT_GOAL := help
  3. define BROWSER_PYSCRIPT
  4. import os, webbrowser, sys
  5. try:
  6. from urllib import pathname2url
  7. except:
  8. from urllib.request import pathname2url
  9. webbrowser.open("file://" + pathname2url(os.path.abspath(sys.argv[1])))
  10. endef
  11. export BROWSER_PYSCRIPT
  12. define PRINT_HELP_PYSCRIPT
  13. import re, sys
  14. for line in sys.stdin:
  15. match = re.match(r'^([a-zA-Z_-]+):.*?## (.*)$$', line)
  16. if match:
  17. target, help = match.groups()
  18. print("%-20s %s" % (target, help))
  19. endef
  20. export PRINT_HELP_PYSCRIPT
  21. BROWSER := python3 -c "$$BROWSER_PYSCRIPT"
  22. help:
  23. @python3 -c "$$PRINT_HELP_PYSCRIPT" < $(MAKEFILE_LIST)
  24. clean: clean-build clean-pyc clean-test ## remove all build, test, coverage and Python artifacts
  25. clean-build: ## remove build artifacts
  26. rm -fr build/
  27. rm -fr dist/
  28. rm -fr .eggs/
  29. find . -name '*.egg-info' -exec rm -fr {} +
  30. find . -name '*.egg' -exec rm -f {} +
  31. clean-pyc: ## remove Python file artifacts
  32. find . -name '*.pyc' -exec rm -f {} +
  33. find . -name '*.pyo' -exec rm -f {} +
  34. find . -name '*~' -exec rm -f {} +
  35. find . -name '__pycache__' -exec rm -fr {} +
  36. clean-test: ## remove test and coverage artifacts
  37. rm -fr .tox/
  38. rm -f .coverage
  39. rm -fr htmlcov/
  40. lint: ## check style with flake8
  41. flake8 face_recognition tests
  42. test: ## run tests quickly with the default Python
  43. python3 setup.py test
  44. test-all: ## run tests on every Python version with tox
  45. tox
  46. coverage: ## check code coverage quickly with the default Python
  47. coverage run --source face_recognition setup.py test
  48. coverage report -m
  49. coverage html
  50. $(BROWSER) htmlcov/index.html
  51. docs: ## generate Sphinx HTML documentation, including API docs
  52. sphinx-apidoc -o docs/ face_recognition
  53. $(MAKE) -C docs clean
  54. $(MAKE) -C docs html
  55. $(BROWSER) docs/_build/html/index.html
  56. servedocs: docs ## compile the docs watching for changes
  57. watchmedo shell-command -p '*.rst' -c '$(MAKE) -C docs html' -R -D .
  58. release: clean ## package and upload a release
  59. python3 setup.py sdist upload
  60. python3 setup.py bdist_wheel upload
  61. dist: clean ## builds source and wheel package
  62. python3 setup.py sdist
  63. python3 setup.py bdist_wheel
  64. ls -l dist
  65. install: clean ## install the package to the active Python's site-packages
  66. python3 setup.py install
Tip!

Press p or to see the previous file or, n or to see the next file

Comments

Loading...