Commit d63e41b4 authored by Tim-Philipp Müller's avatar Tim-Philipp Müller

upload-doc.mak: upload release docs to the right place

On our website, all doc links point to the docs for head, which
is where git docs get uploaded to, while release docs for some
reason get uploaded to docs/$version where no one will ever
find them. Change upload rule to upload release docs to both
the versioned directory and head, so that new docs will actually
be visible on the website when the new-release script in www
uploads them as part of the release process.
parent 564476d8
......@@ -18,13 +18,7 @@ DOC_BASE = /srv/gstreamer.freedesktop.org/www/data/doc
DOC_URL = $(DOC_SERVER):$(DOC_BASE)
upload: $(FORMATS)
@if test "x$(PACKAGE_VERSION_NANO)" = x0; then \
export DOCVERSION=$(VERSION); \
else export DOCVERSION=head; \
fi; \
export DIR=$(DOC_BASE)/gstreamer/$$DOCVERSION/$(DOC); \
ssh $(DOC_SERVER) mkdir -p $$DIR; \
if echo $(FORMATS) | grep html > /dev/null; then \
@if echo $(FORMATS) | grep html > /dev/null; then \
echo "Preparing docs for upload (rebasing cross-references) ..." ; \
if test x$(builddir) != x$(srcdir); then \
echo "make upload can only be used if srcdir == builddir"; \
......@@ -49,9 +43,22 @@ upload: $(FORMATS)
fi; \
if echo $(FORMATS) | grep ps > /dev/null; then export SRC="$$SRC $(DOC).ps"; fi; \
if echo $(FORMATS) | grep pdf > /dev/null; then export SRC="$$SRC $(DOC).pdf"; fi; \
\
# upload releases to both 0.10.X/ and head/ subdirectories \
if test "x$(PACKAGE_VERSION_NANO)" = x0; then \
export DIR=$(DOC_BASE)/gstreamer/$(VERSION)/$(DOC); \
echo Uploading $$SRC to $(DOC_SERVER):$$DIR; \
ssh $(DOC_SERVER) mkdir -p $$DIR; \
rsync -rv -e ssh --delete $$SRC $(DOC_SERVER):$$DIR; \
ssh $(DOC_SERVER) chmod -R g+w $$DIR; \
fi; \
\
export DIR=$(DOC_BASE)/gstreamer/head/$(DOC); \
echo Uploading $$SRC to $(DOC_SERVER):$$DIR; \
ssh $(DOC_SERVER) mkdir -p $$DIR; \
rsync -rv -e ssh --delete $$SRC $(DOC_SERVER):$$DIR; \
ssh $(DOC_SERVER) chmod -R g+w $$DIR; \
\
if echo $(FORMATS) | grep html > /dev/null; then \
echo "Un-preparing docs for upload (rebasing cross-references) ..." ; \
gtkdoc-rebase --html-dir=$(builddir)/html ; \
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment