Skip to content

Commit 99efc28

Browse files
authored
Merge pull request #1914 from RonnyPfannschmidt/docs-remove-getdoctarget
docs: remove the need for special scripts
2 parents 8a41b26 + a2b8981 commit 99efc28

File tree

3 files changed

+3
-39
lines changed

3 files changed

+3
-39
lines changed

doc/en/Makefile

Lines changed: 1 addition & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -19,10 +19,9 @@ REGENDOC_ARGS := \
1919
--normalize "@/tmp/pytest-of-.*/pytest-\d+@PYTEST_TMPDIR@" \
2020

2121

22-
2322
.PHONY: help clean html dirhtml singlehtml pickle json htmlhelp qthelp devhelp epub latex latexpdf text man changes linkcheck doctest
2423

25-
24+
2625
help:
2726
@echo "Please use \`make <target>' where <target> is one of"
2827
@echo " html to make standalone HTML files"
@@ -36,22 +35,6 @@ help:
3635
clean:
3736
-rm -rf $(BUILDDIR)/*
3837

39-
SITETARGET=$(shell ./_getdoctarget.py)
40-
41-
showtarget:
42-
@echo $(SITETARGET)
43-
44-
install: html
45-
# for access talk to someone with login rights to
46-
# [email protected] to add your ssh key
47-
rsync -avz _build/html/ [email protected]:pytest.org/$(SITETARGET)
48-
49-
installpdf: latexpdf
50-
@scp $(BUILDDIR)/latex/pytest.pdf [email protected]:pytest.org/$(SITETARGET)
51-
52-
installall: clean install installpdf
53-
@echo "done"
54-
5538
regen:
5639
PYTHONDONTWRITEBYTECODE=1 COLUMNS=76 regendoc --update *.rst */*.rst ${REGENDOC_ARGS}
5740

doc/en/_getdoctarget.py

Lines changed: 0 additions & 16 deletions
This file was deleted.

doc/en/conf.py

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -19,11 +19,8 @@
1919
# The short X.Y version.
2020

2121
import os, sys
22-
sys.path.insert(0, os.path.dirname(__file__))
23-
import _getdoctarget
24-
25-
version = _getdoctarget.get_minor_version_string()
26-
release = _getdoctarget.get_version_string()
22+
from _pytest import __version__ as version
23+
release = ".".join(version.split(".")[:2])
2724

2825
# If extensions (or modules to document with autodoc) are in another directory,
2926
# add these directories to sys.path here. If the directory is relative to the

0 commit comments

Comments
 (0)