File: Makefile

package info (click to toggle)
python-django-debug-toolbar 1%3A1.9.1-1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 1,480 kB
  • sloc: python: 3,346; makefile: 191; sh: 1
file content (44 lines) | stat: -rw-r--r-- 1,169 bytes parent folder | download
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
.PHONY: flake8 example test coverage translatable_strings update_translations

flake8:
	flake8 debug_toolbar example tests

isort:
	isort -rc debug_toolbar example tests

isort_check_only:
	isort -rc -c debug_toolbar example tests

example:
	DJANGO_SETTINGS_MODULE=example.settings \
		django-admin runserver

jshint: node_modules/jshint/bin/jshint
	./node_modules/jshint/bin/jshint debug_toolbar/static/debug_toolbar/js/*.js

node_modules/jshint/bin/jshint:
	npm install jshint --prefix .

test:
	DJANGO_SETTINGS_MODULE=tests.settings \
		django-admin test $${TEST_ARGS:-tests}

test_selenium:
	DJANGO_SELENIUM_TESTS=true DJANGO_SETTINGS_MODULE=tests.settings \
		django-admin test $${TEST_ARGS:-tests}

coverage:
	python --version
	coverage erase
	DJANGO_SETTINGS_MODULE=tests.settings \
		coverage run `which django-admin` test -v2 $${TEST_ARGS:-tests}
	coverage report
	coverage html

translatable_strings:
	cd debug_toolbar && django-admin makemessages -l en --no-obsolete
	@echo "Please commit changes and run 'tx push -s' (or wait for Transifex to pick them)"

update_translations:
	tx pull -a --minimum-perc=10
	cd debug_toolbar && django-admin compilemessages