Skip to content

Commit

Permalink
feat: Improve documentation by providing multi-pages
Browse files Browse the repository at this point in the history
  • Loading branch information
NicolasGeraud committed Dec 19, 2016
1 parent 7da99b2 commit 6f89f48
Show file tree
Hide file tree
Showing 185 changed files with 13,154 additions and 1,083 deletions.
2 changes: 2 additions & 0 deletions .gitignore
Expand Up @@ -21,3 +21,5 @@ build/
.settings/
.classpath
.project
_site/
.jekyll-metadata
6 changes: 6 additions & 0 deletions 404.md
@@ -0,0 +1,6 @@
---
title: "Page Not Found"
search: exclude
---

Sorry, but the page you were trying to view does not exist. Try searching for it or looking at the URL to see if it looks correct.
2 changes: 1 addition & 1 deletion Dockerfile
Expand Up @@ -13,5 +13,5 @@
FROM graviteeio/httpd:latest
MAINTAINER Gravitee Team <http://gravitee.io>

COPY target/generated-docs/htmlsingle /var/www/html/
COPY _site /var/www/html/
CMD ["/usr/sbin/httpd", "-DFOREGROUND"]
37 changes: 37 additions & 0 deletions Dockerfile-build
@@ -0,0 +1,37 @@
#-------------------------------------------------------------------------------
# Copyright (C) 2015 The Gravitee team (http://gravitee.io)
# 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.
#-------------------------------------------------------------------------------
FROM ruby:latest
MAINTAINER Gravitee Team <http://gravitee.io>

RUN apt-get clean \
&& mv /var/lib/apt/lists /var/lib/apt/lists.broke \
&& mkdir -p /var/lib/apt/lists/partial

RUN apt-get update

RUN apt-get install -y \
node \
python-pygments \
&& apt-get clean \
&& rm -rf /var/lib/apt/lists/

WORKDIR /tmp
ADD Gemfile /tmp/
ADD Gemfile.lock /tmp/
RUN bundle install

VOLUME /src
EXPOSE 4000

WORKDIR /src
ENTRYPOINT ["jekyll"]
12 changes: 12 additions & 0 deletions Gemfile
@@ -0,0 +1,12 @@
source "https://rubygems.org"


gem "jekyll", "3.3.1"


group :jekyll_plugins do
gem "jekyll-feed", "~> 0.6"
gem 'github-pages', '~> 106'
gem 'jekyll-asciidoc', '~> 2.0.1'
gem 'pygments.rb', '~> 1.0.0'
end
161 changes: 161 additions & 0 deletions Gemfile.lock
@@ -0,0 +1,161 @@
GEM
remote: https://rubygems.org/
specs:
activesupport (4.2.7)
i18n (~> 0.7)
json (~> 1.7, >= 1.7.7)
minitest (~> 5.1)
thread_safe (~> 0.3, >= 0.3.4)
tzinfo (~> 1.1)
addressable (2.4.0)
asciidoctor (1.5.5)
coffee-script (2.4.1)
coffee-script-source
execjs
coffee-script-source (1.11.1)
colorator (1.1.0)
ethon (0.10.1)
ffi (>= 1.3.0)
execjs (2.7.0)
faraday (0.10.0)
multipart-post (>= 1.2, < 3)
ffi (1.9.14)
forwardable-extended (2.6.0)
gemoji (2.1.0)
github-pages (106)
activesupport (= 4.2.7)
github-pages-health-check (= 1.2.0)
jekyll (= 3.3.1)
jekyll-avatar (= 0.4.2)
jekyll-coffeescript (= 1.0.1)
jekyll-feed (= 0.8.0)
jekyll-gist (= 1.4.0)
jekyll-github-metadata (= 2.2.0)
jekyll-mentions (= 1.2.0)
jekyll-paginate (= 1.1.0)
jekyll-redirect-from (= 0.11.0)
jekyll-relative-links (= 0.2.1)
jekyll-sass-converter (= 1.3.0)
jekyll-seo-tag (= 2.1.0)
jekyll-sitemap (= 0.12.0)
jekyll-swiss (= 0.4.0)
jemoji (= 0.7.0)
kramdown (= 1.11.1)
liquid (= 3.0.6)
listen (= 3.0.6)
mercenary (~> 0.3)
minima (= 2.0.0)
rouge (= 1.11.1)
terminal-table (~> 1.4)
github-pages-health-check (1.2.0)
addressable (~> 2.3)
net-dns (~> 0.8)
octokit (~> 4.0)
public_suffix (~> 1.4)
typhoeus (~> 0.7)
html-pipeline (2.4.2)
activesupport (>= 2)
nokogiri (>= 1.4)
i18n (0.7.0)
jekyll (3.3.1)
addressable (~> 2.4)
colorator (~> 1.0)
jekyll-sass-converter (~> 1.0)
jekyll-watch (~> 1.1)
kramdown (~> 1.3)
liquid (~> 3.0)
mercenary (~> 0.3.3)
pathutil (~> 0.9)
rouge (~> 1.7)
safe_yaml (~> 1.0)
jekyll-asciidoc (2.0.1)
asciidoctor (>= 1.5.0)
jekyll (>= 2.3.0)
jekyll-avatar (0.4.2)
jekyll (~> 3.0)
jekyll-coffeescript (1.0.1)
coffee-script (~> 2.2)
jekyll-feed (0.8.0)
jekyll (~> 3.3)
jekyll-gist (1.4.0)
octokit (~> 4.2)
jekyll-github-metadata (2.2.0)
jekyll (~> 3.1)
octokit (~> 4.0, != 4.4.0)
jekyll-mentions (1.2.0)
activesupport (~> 4.0)
html-pipeline (~> 2.3)
jekyll (~> 3.0)
jekyll-paginate (1.1.0)
jekyll-redirect-from (0.11.0)
jekyll (>= 2.0)
jekyll-relative-links (0.2.1)
jekyll (~> 3.3)
jekyll-sass-converter (1.3.0)
sass (~> 3.2)
jekyll-seo-tag (2.1.0)
jekyll (~> 3.3)
jekyll-sitemap (0.12.0)
jekyll (~> 3.3)
jekyll-swiss (0.4.0)
jekyll-watch (1.5.0)
listen (~> 3.0, < 3.1)
jemoji (0.7.0)
activesupport (~> 4.0)
gemoji (~> 2.0)
html-pipeline (~> 2.2)
jekyll (>= 3.0)
json (1.8.3)
kramdown (1.11.1)
liquid (3.0.6)
listen (3.0.6)
rb-fsevent (>= 0.9.3)
rb-inotify (>= 0.9.7)
mercenary (0.3.6)
mini_portile2 (2.1.0)
minima (2.0.0)
minitest (5.10.1)
multipart-post (2.0.0)
net-dns (0.8.0)
nokogiri (1.6.8.1)
mini_portile2 (~> 2.1.0)
octokit (4.6.2)
sawyer (~> 0.8.0, >= 0.5.3)
pathutil (0.14.0)
forwardable-extended (~> 2.6)
posix-spawn (0.3.12)
public_suffix (1.5.3)
pygments.rb (1.0.0)
posix-spawn (~> 0.3.6)
yajl-ruby (~> 1.2)
rb-fsevent (0.9.8)
rb-inotify (0.9.7)
ffi (>= 0.5.0)
rouge (1.11.1)
safe_yaml (1.0.4)
sass (3.4.22)
sawyer (0.8.1)
addressable (>= 2.3.5, < 2.6)
faraday (~> 0.8, < 1.0)
terminal-table (1.7.3)
unicode-display_width (~> 1.1.1)
thread_safe (0.3.5)
typhoeus (0.8.0)
ethon (>= 0.8.0)
tzinfo (1.2.2)
thread_safe (~> 0.1)
unicode-display_width (1.1.2)
yajl-ruby (1.3.0)

PLATFORMS
ruby

DEPENDENCIES
github-pages (~> 106)
jekyll (= 3.3.1)
jekyll-asciidoc (~> 2.0.1)
jekyll-feed (~> 0.6)
pygments.rb (~> 1.0.0)

BUNDLED WITH
1.13.6
12 changes: 5 additions & 7 deletions Jenkinsfile
@@ -1,16 +1,14 @@
node() {
sh "rm -rf *"
sh "rm -rf .*"

stage("Checkout") {
checkout scm
}

stage("Build") {
def mvnHome = tool 'MVN33'
def javaHome = tool 'JDK 8'
withEnv(["PATH+MAVEN=${mvnHome}/bin",
"JAVA_HOME=${javaHome}"]) {
sh "mvn clean package"
}
stage("Jekyll Build") {
sh "docker build --no-cache -t gravitee.io/jekyll -f Dockerfile-build ."
sh "docker run --rm -v '${env.WORKSPACE}:/src' gravitee.io/jekyll build"
}

stage("Docker Build & Push") {
Expand Down
117 changes: 117 additions & 0 deletions _config.yml
@@ -0,0 +1,117 @@

output: web
# this property is useful for conditional filtering of content that is separate from the PDF.

topnav_title: Gravitee.io
# this appears on the top navigation bar next to the home button

site_title: Gravitee.io documentation
# this appears in the html browser tab for the site title (seen mostly by search engines, not users)

company_name: GraviteeSource
# this appears in the footer

github_editme_path: gravitee-io/gravitee-docs/blob/pages/
# if you're using Github, provide the basepath to the branch you've created for reviews, following the sample here. if not, leave this value blank.

disqus_shortname:
# if you're using disqus for comments, add the shortname here. if not, leave this value blank.

host: 127.0.0.1
# the preview server used. Leave as is.
port: 4000
# the port where the preview is rendered. You can leave this as is unless you have other Jekyll builds using this same port that might cause conflicts. in that case, use another port such as 4006.

exclude:
- .idea/
- .gitignore
- README.adoc
- CONTRIBUTING.adoc
- src/
# these are the files and directories that jekyll will exclude from the build

feedback_subject_line:
feedback_email:
# used as a contact email for the Feedback link in the top navigation bar
feedback_disable: true
# if you uncomment the previous line, the Feedback link gets removed
# feedback_text: "Need help?"
# if you uncomment the previous line, it changes the Feedback text
# feedback_link: "http://helpy.io/"
# if you uncomment the previous line, it changes where the feedback link points to

highlighter: rouge
# library used for syntax highlighting

#markdown: kramdown
#kramdown:
# input: GFM
# auto_ids: true
# hard_wrap: false
# syntax_highlighter: rouge

# filter used to process markdown. note that kramdown differs from github-flavored markdown in some subtle ways

collections:
tooltips:
output: true
# collections are declared here. this renders the content in _tooltips and processes it, but doesn't output it as actual files in the output unless you change output to true

defaults:
-
scope:
path: ""
type: "pages"
values:
layout: "page"
comments: true
search: true
sidebar: home_sidebar
# -
# scope:
# path: ""
# type: "tooltips"
# values:
# layout: "page"
# comments: true
# search: true
# tooltip: true
#
# -
# scope:
# path: ""
# type: "posts"
# values:
# layout: "post"
# comments: true
# search: true
# sidebar: home_sidebar

# these are defaults used for the frontmatter for these file types

sidebars:
- apim_sidebar
- mydoc_sidebar
- product1_sidebar
- product2_sidebar
- other

description: "Intended as a documentation theme based on Jekyll for technical writers documenting software and other technical products, this theme has all the elements you would need to handle multiple products with both multi-level sidebar navigation, tags, and other documentation features."
# the description is used in the feed.xml file

# needed for sitemap.xml file only
url: https://docs.gravitee.io

asciidoc: {}
asciidoctor:
base_dir: :docdir
safe: unsafe
attributes:
- doctype=book
- idseparator=_
- icons=font
- allow-uri-read=true
- imagesdir=/images
- source-highlighter=pygments
- stylesdir=css

15 changes: 15 additions & 0 deletions _data/alerts.yml
@@ -0,0 +1,15 @@
tip: '<div class="alert alert-success" role="alert"><i class="fa fa-check-square-o"></i> <b>Tip: </b>'
note: '<div class="alert alert-info" role="alert"><i class="fa fa-info-circle"></i> <b>Note: </b>'
important: '<div class="alert alert-warning" role="alert"><i class="fa fa-warning"></i> <b>Important: </b>'
warning: '<div class="alert alert-danger" role="alert"><i class="fa fa-exclamation-circle"></i> <b>Warning: </b>'
end: '</div>'

callout_danger: '<div class="bs-callout bs-callout-danger">'
callout_default: '<div class="bs-callout bs-callout-default">'
callout_primary: '<div class="bs-callout bs-callout-primary">'
callout_success: '<div class="bs-callout bs-callout-success">'
callout_info: '<div class="bs-callout bs-callout-info">'
callout_warning: '<div class="bs-callout bs-callout-warning">'

hr_faded: '<hr class="faded"/>'
hr_shaded: '<hr class="shaded"/>'

0 comments on commit 6f89f48

Please sign in to comment.