Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
24 commits
Select commit Hold shift + click to select a range
78dca9e
Add toc.js for auto generating TOC
AhyoungRyu Jun 17, 2016
1f10b97
Change toc configuration
AhyoungRyu Jun 17, 2016
587d4ba
Apply auto TOC to all of docs under docs/security/
AhyoungRyu Jun 17, 2016
9c5f76b
Apply auto TOC to all of docs under docs/interpreter/
AhyoungRyu Jun 17, 2016
bef398e
Apply auto TOC to all of docs under docs/development/
AhyoungRyu Jun 17, 2016
163691c
Apply auto TOC to all of docs under docs/manual/
AhyoungRyu Jun 17, 2016
b05365f
Apply auto TOC to all of docs under docs/rest-api/
AhyoungRyu Jun 17, 2016
f35db47
Apply auto TOC to all of docs under docs/displaysystem/
AhyoungRyu Jun 17, 2016
db76eb6
Apply auto TOC to all of docs under docs/install/
AhyoungRyu Jun 17, 2016
fbde57f
Apply auto TOC to all of docs under docs/quickstart/
AhyoungRyu Jun 17, 2016
6760c00
Apply auto TOC to all of docs under docs/storage/
AhyoungRyu Jun 17, 2016
6a788fe
Resize TOC tab indent
AhyoungRyu Jun 17, 2016
d114a9d
Address @felixcheung feedback
AhyoungRyu Jun 17, 2016
3fae7df
Apply auto generated toc to install.md
AhyoungRyu Jun 20, 2016
a03ca99
Exclude toc.js from pom.xml
AhyoungRyu Jun 20, 2016
3ffb383
Remove duplicated info in r.md & apply toc
AhyoungRyu Jun 21, 2016
d00e4b1
Move interpreter/screenshot/ -> asset/../img/docs-img/
AhyoungRyu Jun 21, 2016
6394c70
Fix image path in python.md
AhyoungRyu Jun 21, 2016
388f35a
Add jekyll-table-of-contents license info
AhyoungRyu Jun 23, 2016
cf0911c
Rename license file
AhyoungRyu Jun 23, 2016
b7cbe5f
Fix typo
AhyoungRyu Jun 23, 2016
04cf501
Revert 'where to start' section
AhyoungRyu Jun 24, 2016
009579b
Add more info to 'What is the next?' in install.md
AhyoungRyu Jun 24, 2016
e66397b
Apply TOC to interpreterinstallation.md
AhyoungRyu Jun 25, 2016
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 7 additions & 1 deletion LICENSE
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,13 @@ The text of each license is also included at licenses/LICENSE-[project]-[version
(The MIT License) jekyll-bootstrap 0.3.0 (https://github.com/plusjade/jekyll-bootstrap) - https://github.com/plusjade/jekyll-bootstrap
(The MIT License) jekyll 1.3.0 (http://jekyllrb.com/) - https://github.com/jekyll/jekyll/blob/v1.3.0/LICENSE


========================================================================
MIT-style licenses
========================================================================
The following components are provided under the MIT-style license. See project link for details.
The text of each license is also included at licenses/LICENSE-[project]-[version].txt.

(MIT Style) jekyll-table-of-contents (https://github.com/ghiculescu/jekyll-table-of-contents) - https://github.com/ghiculescu/jekyll-table-of-contents/blob/master/LICENSE.txt

========================================================================
Apache licenses
Expand Down
1 change: 1 addition & 0 deletions docs/_includes/themes/zeppelin/default.html
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@
<script src="{{ ASSET_PATH }}/bootstrap/js/bootstrap.min.js"></script>
<script src="{{ ASSET_PATH }}/js/docs.js"></script>
<script src="{{ ASSET_PATH }}/js/anchor.min.js"></script>
<script src="{{ ASSET_PATH }}/js/toc.js"></script>

<!-- atom & rss feed -->
<link href="{{ BASE_PATH }}{{ site.JB.atom_path }}" type="application/atom+xml" rel="alternate" title="Sitewide ATOM Feed">
Expand Down
14 changes: 14 additions & 0 deletions docs/assets/themes/zeppelin/css/style.css
Original file line number Diff line number Diff line change
Expand Up @@ -545,6 +545,20 @@ a.anchor {

a.anchorjs-link:hover { text-decoration: none; }

/* Table of Contents(TOC) */
#toc {
padding-top: 12px;
padding-bottom: 12px;
}

#toc ul {
margin-left: -14px;
}

#toc ul ul {
margin-left: -18px;
}

/* Custom, iPhone Retina */
@media only screen and (max-width: 480px) {
.jumbotron h1 {
Expand Down
4 changes: 4 additions & 0 deletions docs/assets/themes/zeppelin/js/docs.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,6 +118,10 @@ $(function() {
maybeScrollToHash();
});

$(document).ready(function() {
$('#toc').toc();
});

// Scroll now too in case we had opened the page on a hash, but wait a bit because some browsers
// will try to do *their* initial scroll after running the onReady handler.
$(window).load(function() { setTimeout(function() { maybeScrollToHash(); }, 25); });
Expand Down
98 changes: 98 additions & 0 deletions docs/assets/themes/zeppelin/js/toc.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,98 @@
// https://github.com/ghiculescu/jekyll-table-of-contents
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could you add license entry of toc.js into LICENSE file and make a copy of license under licenses directory, while this file will be included in our source distribution?

Copy link
Contributor Author

@AhyoungRyu AhyoungRyu Jun 23, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@Leemoonsoo Yeah I added the license info as you said.

(function($){
$.fn.toc = function(options) {
var defaults = {
noBackToTopLinks: false,
title: '<i></i>',
minimumHeaders: 2,
headers: 'h2, h3',
listType: 'ul', // values: [ol|ul]
showEffect: 'none', // values: [show|slideDown|fadeIn|none]
showSpeed: '0', // set to 0 to deactivate effect
classes: { list: '',
item: ''
}
},
settings = $.extend(defaults, options);

function fixedEncodeURIComponent (str) {
return encodeURIComponent(str).replace(/[!'()*]/g, function(c) {
return '%' + c.charCodeAt(0).toString(16);
});
}

function createLink (header) {
var innerText = (header.textContent === undefined) ? header.innerText : header.textContent;
return "<a href='#" + fixedEncodeURIComponent(header.id) + "'>" + innerText + "</a>";
}

var headers = $(settings.headers).filter(function() {
// get all headers with an ID
var previousSiblingName = $(this).prev().attr( "name" );
if (!this.id && previousSiblingName) {
this.id = $(this).attr( "id", previousSiblingName.replace(/\./g, "-") );
}
return this.id;
}), output = $(this);
if (!headers.length || headers.length < settings.minimumHeaders || !output.length) {
$(this).hide();
return;
}

if (0 === settings.showSpeed) {
settings.showEffect = 'none';
}

var render = {
show: function() { output.hide().html(html).show(settings.showSpeed); },
slideDown: function() { output.hide().html(html).slideDown(settings.showSpeed); },
fadeIn: function() { output.hide().html(html).fadeIn(settings.showSpeed); },
none: function() { output.html(html); }
};

var get_level = function(ele) { return parseInt(ele.nodeName.replace("H", ""), 10); };
var highest_level = headers.map(function(_, ele) { return get_level(ele); }).get().sort()[0];
var return_to_top = '<i class="icon-arrow-up back-to-top"> </i>';

var level = get_level(headers[0]),
this_level,
html = settings.title + " <" +settings.listType + " class=\"" + settings.classes.list +"\">";
headers.on('click', function() {
if (!settings.noBackToTopLinks) {
window.location.hash = this.id;
}
})
.addClass('clickable-header')
.each(function(_, header) {
this_level = get_level(header);
if (!settings.noBackToTopLinks && this_level === highest_level) {
$(header).addClass('top-level-header').after(return_to_top);
}
if (this_level === level) // same level as before; same indenting
html += "<li class=\"" + settings.classes.item + "\">" + createLink(header);
else if (this_level <= level){ // higher level than before; end parent ol
for(i = this_level; i < level; i++) {
html += "</li></"+settings.listType+">"
}
html += "<li class=\"" + settings.classes.item + "\">" + createLink(header);
}
else if (this_level > level) { // lower level than before; expand the previous to contain a ol
for(i = this_level; i > level; i--) {
html += "<" + settings.listType + " class=\"" + settings.classes.list +"\">" +
"<li class=\"" + settings.classes.item + "\">"
}
html += createLink(header);
}
level = this_level; // update for the next one
});
html += "</"+settings.listType+">";
if (!settings.noBackToTopLinks) {
$(document).on('click', '.back-to-top', function() {
$(window).scrollTop(0);
window.location.hash = '';
});
}

render[settings.showEffect]();
};
})(jQuery);
25 changes: 13 additions & 12 deletions docs/development/howtocontribute.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,9 @@ group: development

# Contributing to Apache Zeppelin ( Code )

## IMPORTANT
Apache Zeppelin is an [Apache2 License](http://www.apache.org/licenses/LICENSE-2.0.html) Software.
<div id="toc"></div>

> **NOTE :** Apache Zeppelin is an [Apache2 License](http://www.apache.org/licenses/LICENSE-2.0.html) Software.
Any contributions to Zeppelin (Source code, Documents, Image, Website) means you agree with license all your contributions as Apache2 License.

## Setting up
Expand All @@ -22,7 +23,7 @@ Since Zeppelin uses Git for it's SCM system, you need git client installed in yo

You are free to use whatever IDE you prefer, or your favorite command line editor.

### Build Tools
#### Build Tools

To build the code, install

Expand All @@ -46,10 +47,10 @@ You may also want to develop against a specific branch. For example, for branch-
git clone -b branch-0.5.6 git://git.apache.org/zeppelin.git zeppelin
```

#### Fork repository
If you want not only build Zeppelin but also make any changes, then you need fork [Zeppelin github mirror repository](https://github.com/apache/zeppelin) and make a pull request.
Apache Zeppelin follows [Fork & Pull](https://github.com/sevntu-checkstyle/sevntu.checkstyle/wiki/Development-workflow-with-Git:-Fork,-Branching,-Commits,-and-Pull-Request) as a source control workflow.
If you want to not only build Zeppelin but also make any changes, then you need to fork [Zeppelin github mirror repository](https://github.com/apache/zeppelin) and make a pull request.

###Build
### Build

```
mvn install
Expand All @@ -67,6 +68,8 @@ To build with specific spark / hadoop version
mvn install -Dspark.version=x.x.x -Dhadoop.version=x.x.x
```

For the further

### Run Zeppelin server in development mode

```
Expand All @@ -88,21 +91,19 @@ Server will be run on [http://localhost:8080](http://localhost:8080).

Some portions of the Zeppelin code are generated by [Thrift](http://thrift.apache.org). For most Zeppelin changes, you don't need to worry about this. But if you modify any of the Thrift IDL files (e.g. zeppelin-interpreter/src/main/thrift/*.thrift), then you also need to regenerate these files and submit their updated version as part of your patch.

To regenerate the code, install **thrift-0.9.0** and change directory into Zeppelin source directory. and then run following command
To regenerate the code, install **thrift-0.9.2** and change directory into Zeppelin source directory. and then run following command


```
thrift -out zeppelin-interpreter/src/main/java/ --gen java zeppelin-interpreter/src/main/thrift/RemoteInterpreterService.thrift
```


## JIRA
Zeppelin manages its issues in Jira. [https://issues.apache.org/jira/browse/ZEPPELIN](https://issues.apache.org/jira/browse/ZEPPELIN)

## Where to Start
You can find issues for [beginner](https://issues.apache.org/jira/browse/ZEPPELIN-924?jql=project%20%3D%20ZEPPELIN%20and%20status%20%3D%20Open%20and%20labels%20in%20\(beginner%2C%20newbie\)).
You can find issues for <a href="https://issues.apache.org/jira/browse/ZEPPELIN-981?jql=project%20%3D%20ZEPPELIN%20AND%20labels%20in%20(beginner%2C%20newbie)">beginner & newbie</a>

## Stay involved
Contributors should join the Zeppelin mailing lists.

* [dev@zeppelin.apache.org](http://mail-archives.apache.org/mod_mbox/zeppelin-dev/) is for people who want to contribute code to Zeppelin. [subscribe](mailto:dev-subscribe@zeppelin.apache.org?subject=send this email to subscribe), [unsubscribe](mailto:dev-unsubscribe@zeppelin.apache.org?subject=send this email to unsubscribe), [archives](http://mail-archives.apache.org/mod_mbox/zeppelin-dev/)

If you have any issues, create a ticket in [JIRA](https://issues.apache.org/jira/browse/ZEPPELIN).
41 changes: 22 additions & 19 deletions docs/development/howtocontributewebsite.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,49 +7,52 @@ group: development

# Contributing to Apache Zeppelin ( Website )

## IMPORTANT
Apache Zeppelin is an [Apache2 License](http://www.apache.org/licenses/LICENSE-2.0.html) Software.
Any contribution to Zeppelin (Source code, Documents, Image, Website) means you agree license all your contributions as Apache2 License.
<div id="toc"></div>


## Modifying the website
This page will give you an overview of how to build and contribute to the documentation of Apache Zeppelin.
The online documentation at [zeppelin.apache.org](https://zeppelin.apache.org/docs/latest/) is also generated from the files found here.

#### Getting the source code
Website is hosted in 'master' branch under `/docs/` dir.
> **NOTE :** Apache Zeppelin is an [Apache2 License](http://www.apache.org/licenses/LICENSE-2.0.html) Software.
Any contributions to Zeppelin (Source code, Documents, Image, Website) means you agree with license all your contributions as Apache2 License.

First of all, you need the website source code. The official location of mirror for Zeppelin is [http://git.apache.org/zeppelin.git](http://git.apache.org/zeppelin.git).
## Getting the source code
First of all, you need Zeppelin source code. The official location of Zeppelin is [http://git.apache.org/zeppelin.git](http://git.apache.org/zeppelin.git).
Documentation website is hosted in 'master' branch under `/docs/` dir.

### git access

First of all, you need the website source code. The official location of mirror for Zeppelin is [http://git.apache.org/zeppelin.git](http://git.apache.org/zeppelin.git).
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think git.apache.org is the actual source code, not a "mirror", but we are told not to have github.com address here.

Copy link
Contributor Author

@AhyoungRyu AhyoungRyu Jun 17, 2016

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@felixcheung I'm not sure I understood correctly, as you can see in git.apache.org at the first sentence, they said

This is a collection of read-only Git mirrors of Apache codebases.

Am I missing sth ?

Get the source code on your development machine using git.

```
git clone git://git.apache.org/zeppelin.git
cd docs
```
Apache Zeppelin follows [Fork & Pull](https://github.com/sevntu-checkstyle/sevntu.checkstyle/wiki/Development-workflow-with-Git:-Fork,-Branching,-Commits,-and-Pull-Request) as a source control workflow.
If you want to not only build Zeppelin but also make any changes, then you need to fork [Zeppelin github mirror repository](https://github.com/apache/zeppelin) and make a pull request.

#### Build

To build, you'll need to install some prerequisites. Please check 'Build documentation' section in [docs/README.md](https://github.com/apache/zeppelin/blob/master/docs/README.md#build-documentation).
### Build

#### Run website in development mode
You'll need to install some prerequisites to build the code. Please check [Build documentation](https://github.com/apache/zeppelin/blob/master/docs/README.md#build-documentation) section in [docs/README.md](https://github.com/apache/zeppelin/blob/master/docs/README.md).

While you're modifying website, you'll want to see preview of it. Please check 'Run website' section in [docs/README.md](https://github.com/apache/zeppelin/blob/master/docs/README.md#run-website).
### Run website in development mode

You'll be able to access it on [http://localhost:4000](http://localhost:4000) with your web browser.
While you're modifying website, you might want to see preview of it. Please check [Run website](https://github.com/apache/zeppelin/blob/master/docs/README.md#run-website) section in [docs/README.md](https://github.com/apache/zeppelin/blob/master/docs/README.md).
Then you'll be able to access it on [http://localhost:4000](http://localhost:4000) with your web browser.

#### Making a Pull Request
### Making a Pull Request

When you are ready, just make a pull-request.


## Alternative way

You can directly edit .md files in `/docs/` dir at github's web interface and make pull-request immediatly.


## JIRA
Zeppelin manages its issues in Jira. [https://issues.apache.org/jira/browse/ZEPPELIN](https://issues.apache.org/jira/browse/ZEPPELIN)
You can directly edit `.md` files in `/docs/` directory at the web interface of github and make pull-request immediatly.

## Stay involved
Contributors should join the Zeppelin mailing lists.

* [dev@zeppelin.apache.org](http://mail-archives.apache.org/mod_mbox/zeppelin-dev/) is for people who want to contribute code to Zeppelin. [subscribe](mailto:dev-subscribe@zeppelin.apache.org?subject=send this email to subscribe), [unsubscribe](mailto:dev-unsubscribe@zeppelin.apache.org?subject=send this email to unsubscribe), [archives](http://mail-archives.apache.org/mod_mbox/zeppelin-dev/)

If you have any issues, create a ticket in [JIRA](https://issues.apache.org/jira/browse/ZEPPELIN).
Loading