mirror of
https://github.com/ChristianLight/tutor.git
synced 2024-05-28 20:00:49 +00:00
build: 'make help' works nicer on Mac
sed on Mac doesn't seem to understand \n. While I was in here, I fixed some typos.
This commit is contained in:
parent
ac39f9e6c3
commit
f2260006bd
10
Makefile
10
Makefile
|
@ -5,7 +5,7 @@ BLACK_OPTS = --exclude templates ${SRC_DIRS}
|
||||||
|
|
||||||
###### Development
|
###### Development
|
||||||
|
|
||||||
docs: ## Build html documentation
|
docs: ## Build HTML documentation
|
||||||
$(MAKE) -C docs
|
$(MAKE) -C docs
|
||||||
|
|
||||||
compile-requirements: ## Compile requirements files
|
compile-requirements: ## Compile requirements files
|
||||||
|
@ -18,7 +18,7 @@ upgrade-requirements: ## Upgrade requirements files
|
||||||
pip-compile --upgrade requirements/dev.in
|
pip-compile --upgrade requirements/dev.in
|
||||||
pip-compile --upgrade requirements/docs.in
|
pip-compile --upgrade requirements/docs.in
|
||||||
|
|
||||||
build-pythonpackage: build-pythonpackage-tutor ## Build python packages ready to upload to pypi
|
build-pythonpackage: build-pythonpackage-tutor ## Build Python packages ready to upload to pypi
|
||||||
|
|
||||||
build-pythonpackage-tutor: ## Build the "tutor" python package for upload to pypi
|
build-pythonpackage-tutor: ## Build the "tutor" python package for upload to pypi
|
||||||
python setup.py sdist
|
python setup.py sdist
|
||||||
|
@ -26,7 +26,7 @@ build-pythonpackage-tutor: ## Build the "tutor" python package for upload to pyp
|
||||||
push-pythonpackage: ## Push python package to pypi
|
push-pythonpackage: ## Push python package to pypi
|
||||||
twine upload --skip-existing dist/tutor-$(shell make version).tar.gz
|
twine upload --skip-existing dist/tutor-$(shell make version).tar.gz
|
||||||
|
|
||||||
test: test-lint test-unit test-types test-format test-pythonpackage ## Run all tests by decreasing order or priority
|
test: test-lint test-unit test-types test-format test-pythonpackage ## Run all tests by decreasing order of priority
|
||||||
|
|
||||||
test-format: ## Run code formatting tests
|
test-format: ## Run code formatting tests
|
||||||
black --check --diff $(BLACK_OPTS)
|
black --check --diff $(BLACK_OPTS)
|
||||||
|
@ -50,7 +50,7 @@ bootstrap-dev: ## Install dev requirements
|
||||||
pip install .
|
pip install .
|
||||||
pip install -r requirements/dev.txt
|
pip install -r requirements/dev.txt
|
||||||
|
|
||||||
bootstrap-dev-plugins: bootstrap-dev ## Install dev requirement and all supported plugins
|
bootstrap-dev-plugins: bootstrap-dev ## Install dev requirements and all supported plugins
|
||||||
pip install -r requirements/plugins.txt
|
pip install -r requirements/plugins.txt
|
||||||
|
|
||||||
###### Code coverage
|
###### Code coverage
|
||||||
|
@ -125,5 +125,5 @@ version: ## Print the current tutor version
|
||||||
ESCAPE =
|
ESCAPE =
|
||||||
help: ## Print this help
|
help: ## Print this help
|
||||||
@grep -E '^([a-zA-Z_-]+:.*?## .*|######* .+)$$' Makefile \
|
@grep -E '^([a-zA-Z_-]+:.*?## .*|######* .+)$$' Makefile \
|
||||||
| sed 's/######* \(.*\)/\n $(ESCAPE)[1;31m\1$(ESCAPE)[0m/g' \
|
| sed 's/######* \(.*\)/@ $(ESCAPE)[1;31m\1$(ESCAPE)[0m/g' | tr '@' '\n' \
|
||||||
| awk 'BEGIN {FS = ":.*?## "}; {printf "\033[33m%-30s\033[0m %s\n", $$1, $$2}'
|
| awk 'BEGIN {FS = ":.*?## "}; {printf "\033[33m%-30s\033[0m %s\n", $$1, $$2}'
|
||||||
|
|
Loading…
Reference in New Issue
Block a user