#!/bin/sh
# This script copies the most recent cogentdocs book set to
# andrewgate using ssh. The script should be run from the doc/o
# directory. Make sure you have generated recent html output
# from doc/o/cogent-set/ before running this script.
# The title page/TOC for the docs ends up at:
# andrewgate:/cogent/web/latest/cogentdocs/cogentdocs.html
# which from a browser would be:
# andrewgate:/cogent/latest/cogentdocs/cogentdocs.html
checkdir.sh o
cd ../export/
make html
cd html/
echo 'Making a temporary directory on andrewgate (/cogent/web/tmp/)'
ssh andrewgate "mkdir -p /cogent/web/tmp/; exit"
echo ' '
echo 'Copying new cogentdocs-html.tgz to andrewgate:/cogent/web/tmp/...'
scp cogentdocs-html.tgz andrewgate:/cogent/web/tmp/
# This installs into /cogent/web/latest
#echo 'Updating andrewgate:/cogent/web/latest'
#ssh andrewgate "rm -fr /cogent/web/latest/;
# mkdir /cogent/web/latest/;
# cp /cogent/web/tmp/cogentdocs-html.tgz /cogent/web/latest/newdocs.tgz;
# cd /cogent/web/latest/; tar -xzf newdocs.tgz; exit"
#echo ' '
#
#echo 'Updating andrewgate:/cogent/web/latest'
# This installs into /cogent/web/
ssh andrewgate "rm -fr /cogent/web/cogentdocs/;
cp /cogent/web/tmp/cogentdocs-html.tgz /cogent/web/newdocs.tgz;
cd /cogent/web; tar -xzf newdocs.tgz; exit"
echo ' '
echo 'Removing temporary directory andrewgate:/cogent/web/tmp/'
ssh andrewgate "rm -fr /cogent/web/tmp/; exit"
echo 'Done'
Copyright © 1995-2004 by Cogent Real-Time Systems, Inc. All rights reserved.