diff --git a/docs/Makefile b/docs/Makefile --- a/docs/Makefile +++ b/docs/Makefile @@ -25,6 +25,7 @@ sphinx/html: links-stamp apidoc-stamp images-stamp rec-build-stamp links-stamp: + mkdir -p sources/swh bin/ln-sphinx-subprojects touch $@ diff --git a/docs/bin/ln-sphinx-subprojects b/docs/bin/ln-sphinx-subprojects --- a/docs/bin/ln-sphinx-subprojects +++ b/docs/bin/ln-sphinx-subprojects @@ -7,21 +7,14 @@ if [ "$pymodule" = 'swh-docs' ] ; then continue fi - if [ ! -e "$pymodule" -a -d "../../${pymodule}/docs" ] ; then - ln -s "../../${pymodule}/docs" "$pymodule" + if [ -d "../../${pymodule}/swh" ] ; then + cp -r -f --symbolic-link $(realpath ../../${pymodule}/swh/*) sources/swh/ fi done } remove_links () { - for pymodule in $(cd ../../ && bin/ls-py-modules) ; do - if [ "$pymodule" = 'swh-docs' ] ; then - continue - fi - if [ -L "$pymodule" ] ; then - rm "$pymodule" - fi - done + rm -rf sources/swh/ } if [ "$1" = "--remove" ] ; then