[postgis-tickets] r16516 - Update postgis_release_docs recipe for 2.2 (to be same as 2.4, so debbie can build)
Regina Obe
lr at pcorp.us
Sun Apr 1 08:58:29 PDT 2018
Author: robe
Date: 2018-04-01 20:58:29 -0700 (Sun, 01 Apr 2018)
New Revision: 16516
Modified:
branches/2.3/ci/debbie/postgis_release_docs.sh
Log:
Update postgis_release_docs recipe for 2.2 (to be same as 2.4, so debbie can build)
Modified: branches/2.3/ci/debbie/postgis_release_docs.sh
===================================================================
--- branches/2.3/ci/debbie/postgis_release_docs.sh 2018-04-02 03:53:50 UTC (rev 16515)
+++ branches/2.3/ci/debbie/postgis_release_docs.sh 2018-04-02 03:58:29 UTC (rev 16516)
@@ -37,17 +37,30 @@
--with-geosconfig=${PROJECTS}/geos/rel-${GEOS_VER}w${OS_BUILD}/bin/geos-config \
--without-raster
make clean
+
+# generating postgis_svn_revision.h in case hasn't been generated
+if test -f utils/svn_repo_revision.pl; then
+ echo "Generating postgis_svn_revision.h"
+ perl utils/svn_repo_revision.pl
+fi
+export VREV="`cat postgis_svn_revision.h | awk '{print $3}'`"
+echo "SVN is ${VREV}"
cd doc
-mv postgis.xml postgis.xml.orig
+
#sed -e "s:</title>:</title><subtitle><subscript>SVN Revision (<emphasis>${POSTGIS_SVN_REVISION}</emphasis>)</subscript></subtitle>:" postgis.xml.orig > postgis.xml
echo "Micro: $POSTGIS_MICRO_VERSION"
+cp postgis.xml postgis.xml.orig #we for dev will inject stuff into file, so backup original
#inject a development time stamp if we are in development branch
if [[ "$POSTGIS_MICRO_VERSION" == *"dev"* ]]; then
export GIT_TIMESTAMP=`git log -1 --pretty=format:%ct`
- sed -e "s:</title>:</title><subtitle><subscript>DEV TIMESTAMP (<emphasis>${GIT_TIMESTAMP}</emphasis>)</subscript></subtitle>:" postgis.xml.orig > postgis.xml
+ export GIT_TIMESTAMP="`date -d @$GIT_TIMESTAMP`" #convert to UTC date
+ echo "GIT_TIMESTAMP: ${GIT_TIMESTAMP}"
+ export part_old="</title>"
+ export part_new="</title><subtitle><subscript>DEV (<emphasis>$GIT_TIMESTAMP rev. $VREV </emphasis>)</subscript></subtitle>"
+ sed -i 's,'"$part_old"','"$part_new"',' postgis.xml
fi
make pdf
@@ -58,23 +71,23 @@
make -e chunked-html 2>&1 | tee -a doc-errors.log
if [[ "$reference" == *"trunk"* ]]; then #only do this for trunk because only trunk follows transifex
- make update-po
- make -C po/it_IT/ local-html
+ #make update-po
+ #make -C po/it_IT/ local-html
make -C po/pt_BR/ local-html
- make -C po/ja/ local-html
+ #make -C po/ja/ local-html
make -C po/de/ local-html
- make -C po/pt_BR/ local-html
- make -C po/ko_KR/ local-html
+ #make -C po/ko_KR/ local-html
#make pdf-localized
fi
package="doc-html-${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}.${POSTGIS_MICRO_VERSION}.tar.gz"
+
export outdir=html
tar -czf "$package" --exclude='.svn' --exclude='.git' --exclude='image_src' "$outdir"
-mv postgis.xml.orig postgis.xml
+cp postgis.xml.orig postgis.xml
mkdir -p /var/www/postgis_docs/manual-${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}
mkdir -p /var/www/postgis_docs/manual-${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}/images
cp -R html/*.* /var/www/postgis_docs/manual-${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}
@@ -83,3 +96,9 @@
cp -R *.pdf /var/www/postgis_stuff/
cp -R *.epub /var/www/postgis_stuff/
cp -R $package /var/www/postgis_stuff/
+
+if [[ "$POSTGIS_MICRO_VERSION" == *"dev"* ]]; then #rename the files without the micro if it's a development branch
+ mv /var/www/postgis_stuff/doc-html-${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}.${POSTGIS_MICRO_VERSION}.tar.gz /var/www/postgis_stuff/doc-html-${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}.tar.gz
+ mv /var/www/postgis_stuff/postgis-${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}.${POSTGIS_MICRO_VERSION}.pdf /var/www/postgis_stuff/postgis-${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}.pdf
+ mv /var/www/postgis_stuff/postgis-${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}.${POSTGIS_MICRO_VERSION}.epub /var/www/postgis_stuff/postgis-${POSTGIS_MAJOR_VERSION}.${POSTGIS_MINOR_VERSION}.epub
+fi
More information about the postgis-tickets
mailing list