bookkeeper-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From si...@apache.org
Subject bookkeeper git commit: BOOKKEEPER-828: Script for updating docs on website from master branch (ivank via sijie)
Date Wed, 18 Mar 2015 06:18:22 GMT
Repository: bookkeeper
Updated Branches:
  refs/heads/master 68c5b5a40 -> 4a4802ab5


BOOKKEEPER-828: Script for updating docs on website from master branch (ivank via sijie)


Project: http://git-wip-us.apache.org/repos/asf/bookkeeper/repo
Commit: http://git-wip-us.apache.org/repos/asf/bookkeeper/commit/4a4802ab
Tree: http://git-wip-us.apache.org/repos/asf/bookkeeper/tree/4a4802ab
Diff: http://git-wip-us.apache.org/repos/asf/bookkeeper/diff/4a4802ab

Branch: refs/heads/master
Commit: 4a4802ab5ef1a98eb40cd2bfb4b2f76409745220
Parents: 68c5b5a
Author: Sijie Guo <sijie@apache.org>
Authored: Tue Mar 17 23:18:10 2015 -0700
Committer: Sijie Guo <sijie@apache.org>
Committed: Tue Mar 17 23:18:10 2015 -0700

----------------------------------------------------------------------
 CHANGES.txt            |  2 ++
 bin/update-master-docs | 44 ++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 46 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/bookkeeper/blob/4a4802ab/CHANGES.txt
----------------------------------------------------------------------
diff --git a/CHANGES.txt b/CHANGES.txt
index e24aa40..bbbe756 100644
--- a/CHANGES.txt
+++ b/CHANGES.txt
@@ -61,6 +61,8 @@ Trunk (unreleased changes)
 
       BOOKKEEPER-831: Outdated links in tutorial (ivank via sijie)
 
+      BOOKKEEPER-828: Script for updating docs on website from master branch (ivank via sijie)
+
       bookkeeper-client:
 
         BOOKKEEPER-810: Allow to configure TCP connect timeout (Charles Xie via sijie)

http://git-wip-us.apache.org/repos/asf/bookkeeper/blob/4a4802ab/bin/update-master-docs
----------------------------------------------------------------------
diff --git a/bin/update-master-docs b/bin/update-master-docs
new file mode 100644
index 0000000..96319d8
--- /dev/null
+++ b/bin/update-master-docs
@@ -0,0 +1,44 @@
+#!/usr/bin/env bash
+#
+#   Licensed under the Apache License, Version 2.0 (the "License");
+#   you may not use this file except in compliance with the License.
+#   You may obtain a copy of the License at
+#
+#       http://www.apache.org/licenses/LICENSE-2.0
+#
+#   Unless required by applicable law or agreed to in writing, software
+#   distributed under the License is distributed on an "AS IS" BASIS,
+#   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+#   See the License for the specific language governing permissions and
+#   limitations under the License.
+
+set +x
+
+BASEDIR=/tmp/update-master-docs
+mkdir -p $BASEDIR
+
+SVNDIR=$BASEDIR/svn
+
+GITDIR=$BASEDIR/git
+
+rm -rf $SVNDIR
+rm -rf $GITDIR
+
+svn checkout https://svn.apache.org/repos/asf/bookkeeper/site/trunk/content/docs/master $SVNDIR
+svn checkout https://github.com/apache/bookkeeper/trunk $GITDIR
+
+mvn -f $GITDIR/pom.xml -Dnotimestamp javadoc:aggregate
+
+rsync -avP --exclude=.svn $GITDIR/doc/ $SVNDIR/
+rsync -avP --exclude=.svn $GITDIR/target/site/apidocs/ $SVNDIR/apidocs/
+svn add --force $SVNDIR/*
+
+CHANGES=$(svn status $SVNDIR| awk 'BEGIN { COUNT = 0; } /^[A|M]/ { COUNT = COUNT + 1; } END
{ print COUNT }')
+if [ $CHANGES -gt 0 ]; then
+    svn commit -m "Syncing website with master documentation" $SVNDIR
+    echo
+    echo "Now go review on http://bookkeeper.staging.apache.org, and publish if it's ok"
+    echo
+else
+    echo "No changes, submitting nothing"
+fi


Mime
View raw message