summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon McVittie <smcv@collabora.com>2022-09-06 19:46:39 +0100
committerSimon McVittie <smcv@collabora.com>2022-09-06 19:46:39 +0100
commita2f9051cf9e57d3197a882662deddd63d9d1abee (patch)
tree46e68b47ba4c2921028b079c11057ce3effcbd5b
parent1dc495b5c0c83a5866f2c85417510d0cf4fe47a0 (diff)
downloaddbus-python-a2f9051cf9e57d3197a882662deddd63d9d1abee.tar.gz
Fix website update infrastructure
Signed-off-by: Simon McVittie <smcv@collabora.com>
-rw-r--r--.gitignore2
-rw-r--r--Makefile.am20
-rwxr-xr-x[-rw-r--r--]doc/maintainer-update-website.sh2
-rw-r--r--doc/redirects.py8
4 files changed, 16 insertions, 16 deletions
diff --git a/.gitignore b/.gitignore
index 95f9a96..4770e4d 100644
--- a/.gitignore
+++ b/.gitignore
@@ -42,7 +42,7 @@
/dbus_python.egg-info/
/depcomp
/dist/
-/doc/_build/
+/doc/html/
/install-sh
/libtool
/ltmain.sh
diff --git a/Makefile.am b/Makefile.am
index 5d2f7ea..49bac1d 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -423,31 +423,31 @@ uninstall-local-pycache:
rm -fr $(DESTDIR)$(pythondir)/dbus/mainloop/__pycache__
if ENABLE_DOCUMENTATION
-all: doc/_build/.stamp
+all: doc/html/.stamp
-doc/_build/.stamp: $(nobase_python_PYTHON) \
+doc/html/.stamp: $(nobase_python_PYTHON) \
_dbus_bindings.la \
_dbus_glib_bindings.la \
$(sphinx_sources) \
Makefile \
$(NULL)
- rm -rf doc/_build
- $(MKDIR_P) doc/_build
+ rm -rf doc/html
+ $(MKDIR_P) doc/html
abs_top_srcdir='$(abs_top_srcdir)' \
abs_top_builddir='$(abs_top_builddir)' \
DBUS_PYTHON_NO_DEPRECATED=1 \
- $(PYTHON) -m sphinx -b html $(abs_top_srcdir)/doc doc/_build
+ $(PYTHON) -m sphinx -b html $(abs_top_srcdir)/doc doc/html
touch $@
-maintainer-update-website: doc/_build/.stamp
+maintainer-update-website: doc/html/.stamp
DBUS_TOP_SRCDIR="$(abs_top_srcdir)" \
$(PYTHON) $(srcdir)/doc/redirects.py
- rsync -rtvzPp --chmod=Dg+s,ug+rwX,o=rX doc/_build/ \
+ rsync -rtvzPp --chmod=Dg+s,ug+rwX,o=rX doc/html/ \
dbus.freedesktop.org:/srv/dbus.freedesktop.org/www/doc/dbus-python/
-install-data-local-sphinx: doc/_build/.stamp
+install-data-local-sphinx: doc/html/.stamp
$(mkinstalldirs) $(DESTDIR)$(htmldir)
- cp -R doc/_build/* $(DESTDIR)$(htmldir)
+ cp -R doc/html/* $(DESTDIR)$(htmldir)
uninstall-local-sphinx:
rm -fr $(DESTDIR)$(htmldir)
@@ -462,7 +462,7 @@ uninstall-local-sphinx:
endif
clean-local:
- rm -rf doc/_build
+ rm -rf doc/html
check_c_sources = \
$(_dbus_bindings_la_SOURCES) \
diff --git a/doc/maintainer-update-website.sh b/doc/maintainer-update-website.sh
index ce4f155..6ead3e8 100644..100755
--- a/doc/maintainer-update-website.sh
+++ b/doc/maintainer-update-website.sh
@@ -8,5 +8,5 @@ top="$(dirname "$here")"
DBUS_TOP_SRCDIR="$top" python3 "$here/redirects.py"
rsync -rtvzPp --chmod=Dg+s,ug+rwX,o=rX \
- doc/_build/ \
+ doc/html/ \
"${DOC_RSYNC_DEST-dbus.freedesktop.org:/srv/dbus.freedesktop.org/www/doc/dbus-python}/"
diff --git a/doc/redirects.py b/doc/redirects.py
index 8d41a11..49ebf62 100644
--- a/doc/redirects.py
+++ b/doc/redirects.py
@@ -21,23 +21,23 @@ if __name__ == '__main__':
page, dest = line.split(None, 1)
try:
- os.makedirs(os.path.join('doc', '_build', os.path.dirname(page)))
+ os.makedirs(os.path.join('doc', 'html', os.path.dirname(page)))
except OSError:
pass
- assert not os.path.exists(os.path.join('doc', '_build', page))
+ assert not os.path.exists(os.path.join('doc', 'html', page))
if dest.startswith('"'):
assert page.endswith('.txt')
text = dest.strip('"')
- with open(os.path.join('doc', '_build', page), 'w') as writer:
+ with open(os.path.join('doc', 'html', page), 'w') as writer:
writer.write(text)
writer.write('\n')
else:
assert page.endswith('.html')
- with open(os.path.join('doc', '_build', page), 'w') as writer:
+ with open(os.path.join('doc', 'html', page), 'w') as writer:
writer.write(
'<meta http-equiv="refresh" content="0; url={}" />\n'.format(
dest))