File:  [Coherent Logic Development] / freem / scripts / upload-docs
Revision 1.1: download - view: text, annotated - select for diffs
Sun Mar 16 16:08:27 2025 UTC (2 weeks, 4 days ago) by snw
Branches: MAIN
CVS tags: HEAD
Back on cvs-current versioning for continued development

#!/usr/bin/env bash

PGM=$(basename $0)

function usage() {
    echo "usage:  ${PGM} <ssh-server>"
    exit 1
}

if [[ $# != 1 ]]
then
    usage
fi

SSHCRED=$1

if [[ ! -f sem.ver ]]
then
    echo "${PGM}:  not in the root of the freem repository"
    exit 1
else
    NEWVER=$(cat sem.ver)
fi

cd doc/
./crdocs.sh

DOCDIR="//var/www/freem.coherent-logic.com/docs/${NEWVER}/"

ssh "${SSHCRED}" "mkdir ${DOCDIR}"
if [[ $? != 0 ]]
then
    echo "${PGM}:  error creating remote directory"
    exit 1
fi

scp freem.texi freem/*.html freem.ps freem.pdf freem.info.gz "${SSHCRED}:${DOCDIR}/"
if [[ $? != 0 ]]
then
    echo "${PGM}:  error copying docs"
    exit 1
fi

make -f Makefile.orig clean

FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>