From 7385c6a9bd9786f30210b45bedd326c84cb42424 Mon Sep 17 00:00:00 2001 From: Daniel Sperl Date: Fri, 4 Jul 2014 12:40:33 +0200 Subject: [PATCH] added index file to API reference --- sparrow/doc/generate.sh | 26 ++++++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) diff --git a/sparrow/doc/generate.sh b/sparrow/doc/generate.sh index a0a60944..9dc46def 100755 --- a/sparrow/doc/generate.sh +++ b/sparrow/doc/generate.sh @@ -2,12 +2,27 @@ # This script creates a nice API reference documentation for the Sparrow source # and installs it in Xcode. -# -# To execute it, you need the "AppleDoc"-tool. Download it here: +# +# To execute it, you need the "AppleDoc"-tool. Download it here: # http://www.gentlebytes.com/home/appledocapp/ -echo "Please enter the version number (like '1.0'), followed by [ENTER]:" -read version +if [ $# -ne 1 ] +then + echo "Usage: `basename $0` [version]" + echo " (version like '1.0')" + exit 1 +fi + +version=$1 +index_file=index.md + +# write temporary index file + +echo "**The Open Source Game Engine for iOS, v$version**" > $index_file +echo "" >> $index_file +echo "* Homepage: [www.sparrow-framework.org](http://www.sparrow-framework.org)" >> $index_file +echo "* Forum: [forum.sparrow-framework.org](http://forum.sparrow-framework.org)" >> $index_file +echo "* Wiki: [wiki.sparrow-framework.org](http://wiki.sparrow-framework.org)" >> $index_file appledoc \ --project-name "Sparrow Framework" \ @@ -17,6 +32,7 @@ appledoc \ --explicit-crossref \ --ignore ".m" \ --ignore "_Internal.h" \ + --index-desc "index.md" \ --keep-undocumented-objects \ --keep-undocumented-members \ --keep-intermediate-files \ @@ -33,5 +49,7 @@ appledoc \ --output . \ ../src/Classes +rm $index_file + echo echo "Finished."