I am trying to generate docsets for Dash following these instructions: http://kapeli.com/docsets. The problem is, that the script doesn't continue after the wget and doesn't appear to throw any errors. Everything works fine when I copy the script into the Terminal.
I'm using MacOS 10.8.4 and the default bash.
#!/usr/bin/env bash
set -e
mkdir -p $1.docset/Contents/Resources/Documents/
echo "THIS RUNS"
wget -rkp -l3 -np -nH --cut-dirs=1 --directory-prefix="./"$1".docset/Contents/Resources/Documents/" $2
echo "THIS DOES NOT RUN"
sed "s/NAME/$1/g" template > $1.docset/Contents/Info.plist
touch $1.docset/Contents/Resources/docSet.dsidx
# (script continues)
I looked at other posts like My shell script stops after exec but I'm not using exec
here.
Why does the script exit?