File tree 3 files changed +5
-2
lines changed
3 files changed +5
-2
lines changed Original file line number Diff line number Diff line change @@ -339,6 +339,7 @@ def prepare_writing(self, docnames):
339
339
show_sphinx = self .config .html_show_sphinx ,
340
340
has_source = self .config .html_copy_source ,
341
341
show_source = self .config .html_show_sourcelink ,
342
+ sourcelink_suffix = self .config .html_sourcelink_suffix ,
342
343
file_suffix = self .out_suffix ,
343
344
script_files = self .script_files ,
344
345
language = self .config .language ,
Original file line number Diff line number Diff line change @@ -91,7 +91,8 @@ <h3>{{ _('Navigation') }}</h3>
91
91
VERSION : '{{ release|e }}' ,
92
92
COLLAPSE_INDEX : false ,
93
93
FILE_SUFFIX : '{{ ' ' if no_search_suffix else file_suffix }}' ,
94
- HAS_SOURCE : { { has_source| lower } }
94
+ HAS_SOURCE : { { has_source| lower } } ,
95
+ SOURCELINK_SUFFIX : '{{ sourcelink_suffix }}'
95
96
} ;
96
97
</ script >
97
98
{%- for scriptfile in script_files %}
Original file line number Diff line number Diff line change @@ -256,7 +256,8 @@ var Search = {
256
256
displayNextItem();
257
257
});
258
258
} else if (DOCUMENTATION_OPTIONS.HAS_SOURCE) {
259
- $.ajax({url: DOCUMENTATION_OPTIONS.URL_ROOT + '_sources/' + item[5] + (item[5].endsWith('.txt') ? '' : '.txt'),
259
+ var suffix = DOCUMENTATION_OPTIONS.SOURCELINK_SUFFIX;
260
+ $.ajax({url: DOCUMENTATION_OPTIONS.URL_ROOT + '_sources/' + item[5] + (item[5].endsWith(suffix) ? '' : suffix),
260
261
dataType: "text",
261
262
complete: function(jqxhr, textstatus) {
262
263
var data = jqxhr.responseText;
You can’t perform that action at this time.
0 commit comments