blob: fb76fdd83bda86fa61ee17c77502460d33bb0f62 [file] [log] [blame]
OVERVIEW
========
_scripts/jekyll-debug.sh
will launch the docs for viewing at http://localhost:4000/
_scripts/build.sh
will build the site in _site including javadoc for offline browsing
GO LIVE (SNAPSHOT)
------------------
to make the docs live you build.sh then push _site to github brooklyncentral/brooklyncentral.github.com
the following instructions cover this, assuming brooklyncentral.github.com is a sibling dir to the brooklyn project
updating a snapshot version, in /v/VERSION/ on the server:
export TARGET=`pwd -P`/../../brooklyncentral.github.com
export BV=0.4.0 # BROOKLYN_VERSION
# build, copy
if [ ! -f $TARGET/index.html ] ; then echo "could not find docs in $TARGET" ; exit 1 ; fi
_scripts/build.sh || { echo "failed to build docs" ; exit 1 ; }
rm -rf $TARGET/v/$BV
mkdir $TARGET/v/$BV
cp -r _site/* $TARGET/v/$BV/
# and push
pushd $TARGET
git add -A .
git commit -m "updated version docs for version $BV"
git push
popd
RELEASE
-------
when we do a RELEASE we must run the above for e.g. BV=0.4.0
AND must update the files in the root dir of brooklyncentral.github.com
the commands below do this (basically like the process above but
with / in place of /v/$BV and overriding url in _config.yml
with the --url arg below):
# remove old root files
pushd $TARGET
if [ -f start/index.html ] ; then
for x in * ; do if [[ $x != "v" ]] ; then rm -rf $x ; fi ; done
else
echo IN WRONG DIRECTORY $TARGET - export TARGET to continue
exit 1
fi
popd
# build for hosting of / rather than /v/VERSION/
_scripts/build.sh --url "" || { echo "failed to build docs" ; exit 1 ; }
cp -r _site/* $TARGET/
# and git push
pushd $TARGET
git add -A .
git commit -m "updated root docs for version $BV"
git push
popd
// END