You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@livy.apache.org by js...@apache.org on 2017/07/20 19:58:35 UTC

incubator-livy-website git commit: Minor. Updated README and added publish.sh from apache/bahir-website

Repository: incubator-livy-website
Updated Branches:
  refs/heads/master e5e72977d -> 27348bab6


Minor. Updated README and added publish.sh from apache/bahir-website

I've updated the README based on [apache/bahir-website](https://github.com/apache/bahir-website) and included `publish.sh` from that repo based on feedback in [INFRA-14659](https://issues.apache.org/jira/browse/INFRA-14659)

Author: Alex Bozarth <aj...@us.ibm.com>

Closes #1 from ajbozarth/readme.


Project: http://git-wip-us.apache.org/repos/asf/incubator-livy-website/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-livy-website/commit/27348bab
Tree: http://git-wip-us.apache.org/repos/asf/incubator-livy-website/tree/27348bab
Diff: http://git-wip-us.apache.org/repos/asf/incubator-livy-website/diff/27348bab

Branch: refs/heads/master
Commit: 27348bab675ef4386786b99743ed033ccd578acd
Parents: e5e7297
Author: Alex Bozarth <aj...@us.ibm.com>
Authored: Thu Jul 20 12:58:10 2017 -0700
Committer: jerryshao <ss...@hortonworks.com>
Committed: Thu Jul 20 12:58:10 2017 -0700

----------------------------------------------------------------------
 README.md  | 71 +++++++++++++++++++++++++--------------------------------
 publish.sh | 40 ++++++++++++++++++++++++++++++++
 2 files changed, 71 insertions(+), 40 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-livy-website/blob/27348bab/README.md
----------------------------------------------------------------------
diff --git a/README.md b/README.md
index 0c81332..affe933 100644
--- a/README.md
+++ b/README.md
@@ -17,67 +17,58 @@ limitations under the License.
 {% endcomment %}
 -->
 
-# Apache Livy Website
+# Apache Livy (Incubating) Website
 
-This project contains a template web site that aims to follow all the various required
-Apache Website Policies.
+The Apache Livy (Incubating) website was forked from the
+[Apache Website Template](https://github.com/apache/apache-website-template).
 
-This template was generated using [Jekyll](https://jekyllrb.com/).
-
-To use it, copy the `site` directory into your project.  You must also
-include licensing information from the `LICENSE` and `NOTICE` files in
-your own project.
+This website is generated using [Jekyll](https://jekyllrb.com/).
 
 # How to deploy the web site
 
 
-## Setup
-
-```
-1. cd site
-2. svn co https://svn.apache.org/repos/asf/incubator-livy/site target
-3. sudo apt-get install rubygems ruby2.1-dev zlib1g-dev
-4. sudo gem install bundler github-pages jekyll
-5. bundle install
-```
-
-## Add javadoc
+## Installing Jekyll and website dependencies
 
-If your project supports javadoc, you can copy the generated javadoc
-into svn each time you need to re-generate.
+The steps below will install the latest [Jekyll](https://jekyllrb.com/) version
+and any dependencies required to get this website built.
 
 ```
-1. cd ..
-2. mvn -DskipTests site
-3. mv target/site/apidocs site/target
+1. sudo gem install jekyll bundler
+2. cd site
+3. sudo bundle install
 ```
 
+For more information, see [Installing Jekyll](https://jekyllrb.com/docs/installation/).
+
 ## Running locally
 
-Before opening a pull request, you can preview your contributions by
-running from within the directory:
+Before opening a pull request, you can preview your contributions by running from within the directory:
 
 ```
-1. bundle exec jekyll serve
-2. Open [http://localhost:4000](http://localhost:4000)
+1. cd site
+2. bundle exec jekyll serve --watch
+3. Open http://localhost:4000
 ```
 
-## Pushing to site
+## Publishing to live site
+
+Livy is using [gitpubsub](http://www.apache.org/dev/gitpubsub.html) for publishing the website,
+and the live website content is stored in the asf-site git branch.
+
+To publish new contents to the website, commit your changes to master, and use the 'publish.sh' shell script.
 
 ```
-1. cd site/target
-2. svn status
-3. You'll need to `svn add` any new files
-4. svn ci
+1. Make your changes
+2. git commit -a -m "My updates"
+3. git push
+4. ./publish.sh
+5. git push origin asf-site
 ```
 
-Within a few minutes, svnpubsub should kick in and you'll be able to
-see the results at
-[livy.apache.org](https://livy.apache.org/).
+Within a few minutes, gitpubsub should kick in and you'll be able to see the results at
+[livy.incubator.apache.org](https://livy.incubator.apache.org/).
 
 ## Adding contributors
 
-To add a contributor to the project, or to modify existing contributors,
-edit `site/_data/contributors.yml`.
-The [project members]([http://localhost:4000/community-members/]
-list will re-generate.
+To add a contributor to the project, or to modify existing contributors, edit `site/_data/contributors.yml`.
+The [project members](http://localhost:4000/community-members/) list will re-generate.

http://git-wip-us.apache.org/repos/asf/incubator-livy-website/blob/27348bab/publish.sh
----------------------------------------------------------------------
diff --git a/publish.sh b/publish.sh
new file mode 100644
index 0000000..cb563c5
--- /dev/null
+++ b/publish.sh
@@ -0,0 +1,40 @@
+#!/usr/bin/env bash
+#
+# Licensed to the Apache Software Foundation (ASF) under one or more
+# contributor license agreements.  See the NOTICE file distributed with
+# this work for additional information regarding copyright ownership.
+# The ASF licenses this file to you 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 -e
+cd site
+bundle exec jekyll clean
+bundle exec jekyll build -d _site
+COMMIT_HASH=`git rev-parse HEAD`
+cd ..
+git checkout asf-site
+git branch --set-upstream-to=origin/asf-site asf-site
+git pull --rebase
+rm -rf content
+mkdir content
+mv site/_site/* content
+git add content
+echo "Publishing changes from master branch $COMMIT_HASH"
+git commit -a -m "Publishing from $COMMIT_HASH"
+echo "> > >"
+echo " "
+echo "You are now on the asf-site branch"
+echo "Run git push origin asf-site to update the live site."
+echo " "
+echo " "
+set +e