diff --git a/.gitignore b/.gitignore index d3d20557ab..ac56fbb1b9 100644 --- a/.gitignore +++ b/.gitignore @@ -28,4 +28,3 @@ dist build proxy/public -docs/_build diff --git a/Makefile b/Makefile index 9eebd4ac5a..d34b72c2e7 100644 --- a/Makefile +++ b/Makefile @@ -14,6 +14,12 @@ CA_KEY_FILE_PATH := ca-key.pem CA_CERT_FILE_PATH := ca-cert.pem CA_SIGNING_KEY_FILE_PATH := ca-signing-key.pem +OPEN=$(shell which open) +UNAME := $(shell uname) +ifeq ($(UNAME), Linux) +OPEN=$(shell which xdg-open) +endif + .PHONY: all https-certificates sign-https-certificates ca-certificates .PHONY: lib-check lib-clean lib-test lib-package lib-coverage lib-lint lib-pytest .PHONY: lib-release-test lib-release lib-profile lib-doc @@ -89,7 +95,6 @@ lib-dep: -r requirements-testing.txt \ -r requirements-release.txt \ -r requirements-tunnel.txt \ - -r docs/requirements.txt lib-lint: python -m tox -e lint @@ -115,18 +120,12 @@ lib-release: lib-package twine upload dist/* lib-doc: - pushd docs && \ - python -m sphinx \ - --keep-going \ - -b dirhtml \ - -d _build/doctrees \ - -D language=en . _build/html && \ - popd && \ - open docs/_build/html/index.html + python -m tox -e lint && \ + $(OPEN) .tox/build-docs/docs_out/index.html lib-coverage: pytest --cov=proxy --cov=tests --cov-report=html tests/ - open htmlcov/index.html + $(OPEN) htmlcov/index.html lib-profile: sudo py-spy record -o profile.svg -t -F -s -- python -m proxy