change the affected section to this:
#!/bin/bash
# by: orbisvicis
manpath=$(manpath -g)
# Set the bash delimiter
# Spaces are mandatory when creating the array so bash does not becore confused
IFS=:
pathArray=( $manpath )
unset IFS
# From the bash man-pages
# Allow patterns which match no files to expand to a null string rather than
themselves
shopt -s nullglob
for path in "[EMAIL PROTECTED]"
do
# fixing the symlink issue: symlinks to directories will be considered
empty. Undesirable if symlink points outside manpath
# Must also check that the new link value is not already part of the
manpath, dont want to give swish++ duplicate paths
# requires readlink
if [[ -h $path ]];then
echo -n "symlink: "
# This works here due to read order, might not work in other
versions/shells
if [[ $manpath = *$(readlink -n --canonicalize $path)* ]];then
echo -n "duplicate,ignored: "
else
echo -n "redirected to: "
path=$(readlink -n --canonicalize $path)
fi
fi
pathFull=$path"/man*/"
pathGlob=($pathFull)
# verify that the directory exists and contains the /man*/
subdirectories
# Note that this will return a false (no subdirectories) for symlinks
as they are treated as files
# *this can make a difference if the link is not included in the
manpath
(( ${#pathGlob[*]} )) && pathStringExist+=$path":" || echo $path": no
\"man*\" subdirectories"
# Note that now [EMAIL PROTECTED] holds all the elements that matches
the glob
# This is useful for performing operations using [EMAIL PROTECTED]
#echo [EMAIL PROTECTED]
done
# Unset the nullglob option
shopt -u nullglob
IFS=:
pathArrayExist=( $pathStringExist )
unset IFS
echo "[EMAIL PROTECTED]"
if [[ -e /var/cache/man2html/ ]] && [[ -x /usr/bin/index++ ]];then
if [[ -e /var/cache/man2html/man2html.swish++.index ]];then
rm /var/cache/man2html/man2html.swish++.index*
/var/cache/man2html/manindexh* /var/cache/man2html/whatish-*
fi
echo "see /usr/share/man2html for configuration options"
index++ --config-file=/usr/share/man2html/swish++.conf "[EMAIL
PROTECTED]"
echo "Done, recommend restarting webserver"
fi
--
manpage index incomplete, insufficient docs
https://bugs.launchpad.net/bugs/246816
You received this bug notification because you are a member of Ubuntu
Bugs, which is subscribed to Ubuntu.
--
ubuntu-bugs mailing list
[email protected]
https://lists.ubuntu.com/mailman/listinfo/ubuntu-bugs