You are viewing a plain text version of this content. The canonical link for it is here.
Posted to cvs@incubator.apache.org by wa...@apache.org on 2019/04/02 18:04:35 UTC
[incubator] branch master updated: SVN Clutch Analysis and Pages
are separated
This is an automated email from the ASF dual-hosted git repository.
wave pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator.git
The following commit(s) were added to refs/heads/master by this push:
new 86b26c5 SVN Clutch Analysis and Pages are separated
86b26c5 is described below
commit 86b26c56e133e2c2853d1d2d5eb17377ebf8bed5
Author: Dave Fisher <da...@davefisher.tech>
AuthorDate: Tue Apr 2 11:04:31 2019 -0700
SVN Clutch Analysis and Pages are separated
build_clutch.sh now does all the SVN work and checks in the results to Git Master in Pages and Assets.
build_site.sh and build_local.sh are now straightforward and simple.
---
build_clutch.sh | 51 +++++++++++++++++++++++++++++++++++++++++++++++++++
build_local.sh | 31 +------------------------------
build_site.sh | 29 -----------------------------
3 files changed, 52 insertions(+), 59 deletions(-)
diff --git a/build_clutch.sh b/build_clutch.sh
new file mode 100644
index 0000000..22eb2d5
--- /dev/null
+++ b/build_clutch.sh
@@ -0,0 +1,51 @@
+#!/bin/bash
+CURRENTDIR=`pwd`
+SVN_CO_DIR=/tmp/incubator-site-content
+SVN_BUILD_DIR=/tmp/incubator-site-build
+SVN_REPO=http://svn.apache.org/repos/asf/incubator/public/trunk/
+# download the svn bits
+rm -rf $SVN_CO_DIR
+rm -rf $SVN_BUILD_DIR
+svn co $SVN_REPO $SVN_CO_DIR
+if [ $? -gt 0 ]; then
+ echo ABORT: svn checkout error
+ exit 4
+fi
+cd $SVN_CO_DIR
+# build pages the old way
+ant docs -Ddocs.dest=$SVN_BUILD_DIR
+if [ $? -gt 0 ]; then
+ echo ABORT: ant docs error
+ exit 4
+fi
+# run clutch2 analysis
+./clutch2.sh
+if [ $? -gt 0 ]; then
+ echo ABORT: clutch2.sh error
+ exit 4
+fi
+# prepare the git master with updates from svn build and clutch analysis
+cd $CURRENTDIR
+# move in files built using ant in the old style
+# ip clearance as assets
+rm -rf assets/ip-clearance
+mkdir assets/ip-clearance
+cp $SVN_BUILD_DIR/ip-clearance/*.html assets/ip-clearance/.
+# podling status files as assets
+rm -rf assets/projects
+mkdir assets/projects
+cp $SVN_BUILD_DIR/projects/*.html assets/projects/.
+# move in files from the clutch analysis
+# these txt files are moved to assets
+cp $SVN_CO_DIR/content/clutch/*.txt assets/.
+cp $SVN_CO_DIR/content/clutch/*.json assets/.
+# add all of these assets. Assets are used in the baked site as is.
+git add assets/*
+# the following asciidoc clutch files go to be baked
+cp $SVN_CO_DIR/content/clutch/_includes/*.ad pages/clutch/_includes/.
+git add pages/clutch/_includes/*
+cp $SVN_CO_DIR/content/clutch/*.ad pages/clutch/.
+git add pages/clutch/*
+# commit and push the assets and pages to site master
+git commit -m "Automatic Clutch Publish by git-site-role"
+git push origin master
diff --git a/build_local.sh b/build_local.sh
index dd1710a..deac81a 100755
--- a/build_local.sh
+++ b/build_local.sh
@@ -2,39 +2,10 @@
CURRENTDIR=`pwd`
WORKDIR=/tmp/incubator-site
-SVN_CO_DIR=/tmp/incubator-site-content
-SVN_BUILD_DIR=/tmp/incubator-site-build
-SVN_REPO=http://svn.apache.org/repos/asf/incubator/public/trunk/
-# build the git bits
rm -rf $WORKDIR
mkdir -p $WORKDIR
-mkdir -p $WORKDIR/clutch
-# build the svn bits
-rm -rf $SVN_CO_DIR
-rm -rf $SVN_BUILD_DIR
-svn co $SVN_REPO $SVN_CO_DIR
-(
- cd $SVN_CO_DIR
- ant docs -Ddocs.dest=$SVN_BUILD_DIR
- # these files were built using ant in the old style
- mv $SVN_BUILD_DIR/ip-clearance $WORKDIR
- mv $SVN_BUILD_DIR/projects $WORKDIR
- # new clutch2 process
- ./clutch2.sh
- if [ $? -gt 0 ]; then
- echo clutch2.sh returned $? - ABORT
- exit 4
- fi
- # these txt files are moved to output
- cp $SVN_CO_DIR/content/clutch/*.txt $WORKDIR/clutch/.
-)
-
-# the following files go to be baked
-cp $SVN_CO_DIR/content/clutch/_includes/*.ad pages/clutch/_includes/.
-cp $SVN_CO_DIR/content/clutch/*.ad pages/clutch/.
-
-# now bake and serve the site
+# just bake and serve the site
./bake.sh -b -s . $WORKDIR
diff --git a/build_site.sh b/build_site.sh
index 20c7770..321576c 100755
--- a/build_site.sh
+++ b/build_site.sh
@@ -2,38 +2,9 @@
CURRENTDIR=`pwd`
WORKDIR=/tmp/incubator-site
-SVN_CO_DIR=/tmp/incubator-site-content
-SVN_BUILD_DIR=/tmp/incubator-site-build
-SVN_REPO=http://svn.apache.org/repos/asf/incubator/public/trunk/
-# build the git bits
rm -rf $WORKDIR
mkdir -p $WORKDIR
-mkdir -p $WORKDIR/clutch
-
-# build the svn bits
-rm -rf $SVN_CO_DIR
-rm -rf $SVN_BUILD_DIR
-svn co $SVN_REPO $SVN_CO_DIR
-(
- cd $SVN_CO_DIR
- ant docs -Ddocs.dest=$SVN_BUILD_DIR
- # these files were built using ant in the old style
- mv $SVN_BUILD_DIR/ip-clearance $WORKDIR
- mv $SVN_BUILD_DIR/projects $WORKDIR
- # new clutch2 process
- ./clutch2.sh
- if [ $? -gt 0 ]; then
- echo clutch2.sh returned $? - ABORT
- exit 4
- fi
- # these txt files are moved to output
- cp $SVN_CO_DIR/content/clutch/*.txt $WORKDIR/clutch/.
-)
-
-# the following files go to be baked
-cp $SVN_CO_DIR/content/clutch/_includes/*.ad pages/clutch/_includes/.
-cp $SVN_CO_DIR/content/clutch/*.ad pages/clutch/.
# now bake the site
./bake.sh -b . $WORKDIR
---------------------------------------------------------------------
To unsubscribe, e-mail: cvs-unsubscribe@incubator.apache.org
For additional commands, e-mail: cvs-help@incubator.apache.org