Skip to content

Commit

Permalink
Use doxypypy on RTD
Browse files Browse the repository at this point in the history
It handles better Python than doxypy. See https://github.com/Feneric/doxypypy
  • Loading branch information
muffato authored and ens-bwalts committed Nov 11, 2020
1 parent 1a1cfeb commit 38f63c6
Show file tree
Hide file tree
Showing 3 changed files with 22 additions and 5 deletions.
1 change: 1 addition & 0 deletions docs/requirements.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
sphinxcontrib-doxylink==1.3
doxypypy
17 changes: 17 additions & 0 deletions scripts/dev/doxypypy_filter.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
#!/bin/sh
# Copyright [1999-2015] Wellcome Trust Sanger Institute and the EMBL-European Bioinformatics Institute
# Copyright [2016-2020] EMBL-European Bioinformatics Institute
#
# Licensed under the Apache License, Version 2.0 (the "License");
# you may not use this file except in compliance with the License.
# You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing, software
# distributed under the License is distributed on an "AS IS" BASIS,
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
# See the License for the specific language governing permissions and
# limitations under the License.

exec doxypypy -a -c "$1"
9 changes: 4 additions & 5 deletions scripts/dev/make_doxygen.pl
Original file line number Diff line number Diff line change
Expand Up @@ -86,10 +86,9 @@ sub generate_docs_doxygen_python {
chomp $doxy_bin;
die "Cannot run doxygen binary, please make sure it is installed and is in the path.\n" unless(-r $doxy_bin);

my $doxy_filter = `which doxypy`;
chomp $doxy_filter;

die "Cannot find the Doxygen Python filter 'doxypy' in the current PATH.\n" unless -e $doxy_filter;
my $doxypypy = `which doxypypy`;
chomp $doxypypy;
die "Cannot find the Doxygen Python filter 'doxypypy' in the current PATH.\n" unless -e $doxypypy;

my @cmds = (
"rm -rf $doxy_target/python3",
Expand All @@ -100,9 +99,9 @@ sub generate_docs_doxygen_python {
"echo 'OUTPUT_DIRECTORY = $doxy_target'",
"echo 'STRIP_FROM_PATH = $ehrd/wrappers/python3'",
"echo 'INPUT = $ehrd/wrappers/python3'",
"echo 'INPUT_FILTER = $doxy_filter'",
"echo 'HTML_OUTPUT = python3'",
"echo 'FILE_PATTERNS = *.py README.md'",
"echo 'FILTER_PATTERNS = *.py=$ehrd/scripts/dev/doxypypy_filter.sh'",
"echo 'EXTRACT_PRIVATE = YES'",
"echo 'EXTRACT_STATIC = YES'",
"echo 'CLASS_DIAGRAMS = YES'",
Expand Down

0 comments on commit 38f63c6

Please sign in to comment.