[Python-modules-commits] [sphinx] 01/01: dh_sphinxdoc: Turn warning about missing SOURCELINK_SUFFIX to an error.

Dmitry Shachnev mitya57 at moszumanska.debian.org
Sat Sep 23 14:21:25 UTC 2017


This is an automated email from the git hooks/post-receive script.

mitya57 pushed a commit to branch debian/master
in repository sphinx.

commit 365bae2a1f03ad869863befaa7a23b1fd0705df2
Author: Dmitry Shachnev <mitya57 at gmail.com>
Date:   Sat Sep 23 17:19:19 2017 +0300

    dh_sphinxdoc: Turn warning about missing SOURCELINK_SUFFIX to an error.
---
 debian/changelog                 | 6 ++++++
 debian/dh-sphinxdoc/dh_sphinxdoc | 6 +-----
 2 files changed, 7 insertions(+), 5 deletions(-)

diff --git a/debian/changelog b/debian/changelog
index 1100d17..25ace85 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -1,3 +1,9 @@
+sphinx (1.6.3-3) UNRELEASED; urgency=medium
+
+  * dh_sphinxdoc: Turn warning about missing SOURCELINK_SUFFIX to an error.
+
+ -- Dmitry Shachnev <mitya57 at debian.org>  Sat, 23 Sep 2017 17:17:32 +0300
+
 sphinx (1.6.3-2) unstable; urgency=medium
 
   * Move sphinxcontrib-websupport from requirements to extras_require
diff --git a/debian/dh-sphinxdoc/dh_sphinxdoc b/debian/dh-sphinxdoc/dh_sphinxdoc
index 5d53ac5..0d7f602 100755
--- a/debian/dh-sphinxdoc/dh_sphinxdoc
+++ b/debian/dh-sphinxdoc/dh_sphinxdoc
@@ -234,15 +234,11 @@ sub sanity_check($$)
     my $loads_searchindex = $search =~ m/\QjQuery(function() { Search.loadIndex("\E/;
     my ($has_source) = $search =~ m{HAS_SOURCE:\s*(true|false)};
     my ($sourcelink_suffix) = $search =~ m{SOURCELINK_SUFFIX:\s*'([^']*)'};
-    unless (defined $sourcelink_suffix)
-    {
-        warning("SOURCELINK_SUFFIX is not defined in search.html, search will not work!");
-        $sourcelink_suffix = ".txt";
-    }
     my ($url_root) = $search =~ m{URL_ROOT:\s*'([^']*)'};
     %js or error("$searchfn does not include any JavaScript code");
     $is_singlehtml or $loads_searchindex or error("$searchfn does not load searchindex.js");
     defined $has_source or error("DOCUMENTATION_OPTIONS does not define HAS_SOURCE");
+    defined $sourcelink_suffix or error("DOCUMENTATION_OPTIONS does not define SOURCELINK_SUFFIX");
     defined $url_root or error("DOCUMENTATION_OPTIONS does not define URL_ROOT");
     $has_source = $has_source eq 'true';
     $url_root =~ m{^([a-z]+:/)?/} and error("URL_ROOT in $searchfn is not relative");

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/python-modules/packages/sphinx.git



More information about the Python-modules-commits mailing list