Skip to content

Commit

Permalink
add github page for Vitess
Browse files Browse the repository at this point in the history
  • Loading branch information
yaoshengzhe committed Feb 13, 2015
1 parent 718a35b commit 2c0c8fc
Show file tree
Hide file tree
Showing 190 changed files with 8,110 additions and 0 deletions.
30 changes: 30 additions & 0 deletions publish-site.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,30 @@
#! /bin/bash

set -e

git checkout gh-pages

git rm --ignore-unmatch -rf *

git checkout master doc
git checkout master README.md
git checkout master vitess.io

mv doc vitess.io/_includes/
mv README.md vitess.io/_includes/

cd vitess.io
bundle install
bundle exec jekyll build
cd ..

git add vitess.io/_site/*
git mv vitess.io/_site/* .
git add vitess.io/LICENSE
git mv vitess.io/LICENSE .

rm -rf vitess.io
git add -u

git commit -m "publish site `date`"
git push origin gh-pages
1 change: 1 addition & 0 deletions vitess.io/CNAME
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
vitess.io
7 changes: 7 additions & 0 deletions vitess.io/Gemfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
source "https://rubygems.org"

gem 'jekyll', '~> 2.4.0'
gem 'jekyll-sitemap', '~> 0.6.1'
gem 'sass'
gem 'bourbon'
gem 'neat'
95 changes: 95 additions & 0 deletions vitess.io/Gruntfile.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,95 @@
'use strict';
module.exports = function(grunt) {

grunt.initConfig({
pkg: grunt.file.readJSON('package.json'),
jshint: {
options: {
jshintrc: '.jshintrc'
},
all: [
'Gruntfile.js',
'js/*.js',
'!js/main.js'
]
},
watch: {
js: {
files: [
'<%= jshint.all %>'
],
tasks: ['jshint', 'uglify'],
options: {
livereload: true
}
},
},
uglify: {
dist: {
options: {
banner: '/*! <%= pkg.name %> - v<%= pkg.version %> - ' + '<%= grunt.template.today("yyyy-mm-dd") %> */',
compress: true,
beautify: false,
mangle: false
},
files: {
'js/main.js': [
'js/plugins/*.js',
'js/_*.js'
]
}
}
},
imagemin: {
dist: {
options: {
optimizationLevel: 7,
progressive: true
},
files: [{
expand: true,
cwd: 'images/',
src: '{,*/}*.{png,jpg,jpeg}',
dest: 'images/'
}]
}
},
imgcompress: {
dist: {
options: {
optimizationLevel: 7,
progressive: true
},
files: [{
expand: true,
cwd: 'images/',
src: '{,*/}*.{png,jpg,jpeg}',
dest: 'images/'
}]
}
},
svgmin: {
dist: {
files: [{
expand: true,
cwd: 'images/',
src: '{,*/}*.svg',
dest: 'images/'
}]
}
},
});

// Load tasks
grunt.loadNpmTasks('grunt-contrib-jshint');
grunt.loadNpmTasks('grunt-contrib-watch');
grunt.loadNpmTasks('grunt-contrib-uglify');
grunt.loadNpmTasks('grunt-newer');
grunt.loadNpmTasks('grunt-contrib-imagemin');
grunt.loadNpmTasks('grunt-svgmin');
grunt.loadNpmTasks('grunt-imgcompress');

// Register tasks
grunt.registerTask('scripts', ['watch', 'uglify']);
grunt.registerTask('images', ['newer:imgcompress', 'newer:svgmin']);
};
21 changes: 21 additions & 0 deletions vitess.io/LICENSE
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
The MIT License (MIT)

Copyright (c) 2014 Michael Rose

Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all
copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
SOFTWARE.
37 changes: 37 additions & 0 deletions vitess.io/_config.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
# Site wide configuration

title: Vitess
description: "A set of servers and tools meant to facilitate scaling of MySQL databases for the web."
logo: 120x120.gif
teaser: 400x250.gif
locale: en_US
url: http://youtube.github.io/vitess
project-name: Vitess
repo: https://github.com/youtube/vitess

# Jekyll configuration
sass:
sass_dir: _sass
style: compressed
permalink: /:categories/:title/
highlighter: pygments
gems:
- jekyll-sitemap

markdown: redcarpet

redcarpet:
extensions: ["no_intra_emphasis", "fenced_code_blocks", "autolink", "tables", "with_toc_data"]

# Site owner
owner:
name: Vitess Team
web: https://github.com/youtube/vitess
email:
twitter:
bio:
avatar:
disqus-shortname:


exclude: ["lib", "config.rb", ".sass-cache", "Capfile", "config", "log", "Rakefile", "Rakefile.rb", "tmp", "*.sublime-project", "*.sublime-workspace", "Gemfile", "Gemfile.lock", "README.md", "LICENSE", "node_modules", "Gruntfile.js", "package.json"]
11 changes: 11 additions & 0 deletions vitess.io/_data/authors.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
# Authors

shengzhe:
name: Shengzhe
web:
email:
bio:
avatar:
twitter:
google:
plus:
16 changes: 16 additions & 0 deletions vitess.io/_data/footer.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Footer navigation links

- title: Home
url: /

- title: Getting Started
url: /getting-started/

- title: About
url: /about/

- title: FAQ
url: /faq/

- title: Terms
url: /terms/
21 changes: 21 additions & 0 deletions vitess.io/_data/navigation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
# Site navigation links

- title: Getting Started
url: /getting-started/
excerpt: "Everything you need to know to get started with Vitess."
image: 400x250.gif

- title: Documentation
url: /documentation/
excerpt: "Vitess Docs."
image: 400x250.gif

- title: About
url: /about/
excerpt: "All about Vitess."
image: 400x250.gif

- title: FAQ
url: /faq/
excerpt: "Vitess Faq."
image: 400x250.gif
13 changes: 13 additions & 0 deletions vitess.io/_includes/breadcrumbs.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{% if page.categories and page.categories != empty %}
<nav class="breadcrumbs">
<span itemscope itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="{{ site.url }}" itemprop="url">
<span itemprop="title">Home</span>
</a>
<span itemscope itemtype="http://data-vocabulary.org/Breadcrumb">
<a href="{{ site.url }}/{{ page.categories | first }}/" itemprop="url">
<span itemprop="title">{{ page.categories | first | replace: '-',' ' | capitalize }}</span>
</a>
</span>
</nav>
{% endif %}
1 change: 1 addition & 0 deletions vitess.io/_includes/browser-upgrade.html
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
<!--[if lt IE 9]><div class="upgrade notice-danger"><strong>Your browser is quite old!</strong> Why not <a href="http://whatbrowser.org/">upgrade to a newer one</a> to better enjoy this site?</div><![endif]-->
15 changes: 15 additions & 0 deletions vitess.io/_includes/collection-pagination.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<nav class="pagination">
{% capture collection_name %}{{ include.collection }}{% endcapture %}
{% for post in site.[collection_name] %}
{% if post.url == page.url %}
{% assign post_index0 = forloop.index0 %}
{% assign post_index1 = forloop.index %}
{% endif %}
{% endfor %}
{% for post in site.[collection_name] %}
{% if post_index0 == forloop.index %}{% assign next_post = post %}{% endif %}
{% if post_index1 == forloop.index0 %}{% assign prev_post = post %}{% endif %}
{% endfor %}
{% if prev_post %}<a class="prev" href="{{ site.url }}{{ prev_post.url }}">{{ prev_post.title }}</a>{% endif %}
{% if next_post %}<a class="next" href="{{ site.url }}{{ next_post.url }}">{{ next_post.title }}</a>{% endif %}
</nav>
14 changes: 14 additions & 0 deletions vitess.io/_includes/comments.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
<hr />
<div id="disqus_thread"></div>
<script type="text/javascript">
/* * * CONFIGURATION VARIABLES: EDIT BEFORE PASTING INTO YOUR WEBPAGE * * */
var disqus_shortname = '{{ site.disqus-shortname }}';

/* * * DON'T EDIT BELOW THIS LINE * * */
(function() {
var dsq = document.createElement('script'); dsq.type = 'text/javascript'; dsq.async = true;
dsq.src = '//' + disqus_shortname + '.disqus.com/embed.js';
(document.getElementsByTagName('head')[0] || document.getElementsByTagName('body')[0]).appendChild(dsq);
})();
</script>
<noscript>Please enable JavaScript to view the <a href="http://disqus.com/?ref_noscript">comments powered by Disqus.</a></noscript>
15 changes: 15 additions & 0 deletions vitess.io/_includes/footer.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<footer role="contentinfo" id="site-footer">
<nav role="navigation" class="menu bottom-menu">
<ul class="menu-item">
{% for link in site.data.footer %}
{% if link.url contains 'http' %}
{% assign domain = '' %}
{% else %}
{% assign domain = site.url %}
{% endif %}
<li><a href="{{ domain }}{{ link.url }}" {% if link.url contains 'http' %}target="_blank"{% endif %}>{{ link.title }}</a></li>
{% endfor %}
</ul>
</nav>
<p class="copyright">&#169; {{ site.time | date: '%Y' }} <a href="{{ site.url }}">{{ site.title }}</a> powered by <a href="http://www.google.com">Google Inc</a>.</p>
</footer>
8 changes: 8 additions & 0 deletions vitess.io/_includes/header.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
<header id="masthead">
<div class="inner-wrap">
<a href="{{ site.url }}/" class="site-title">{{ site.title }}</a>
<nav role="navigation" class="menu top-menu">
{% include navigation.html %}
</nav>
</div>
</header>
1 change: 1 addition & 0 deletions vitess.io/_includes/image-credit.html
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
<div class="image-credit">Image source: <a href="{{ page.image.creditlink }}" itemprop="citation">{{ page.image.credit }}</a></div>
9 changes: 9 additions & 0 deletions vitess.io/_includes/latest-posts-grid.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<div class="archive-wrap">
<h3>Latest {{ page.categories | first | replace: '-',' ' | capitalize }}</h3>
<ul class="th-grid">
{% capture category_name %}{{ page.categories | first }}{% endcapture %}
{% for post in site.categories.[category_name] limit:4 %}
<li><a href="{{ site.url }}{{ post.url }}" title="{{ post.title }}"><img src="{{ site.url }}/images/{{ post.image.thumb }}" alt=""></a></li>
{% endfor %}
</ul>
</div>
7 changes: 7 additions & 0 deletions vitess.io/_includes/latest-posts-list.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<h3>Latest {{ page.categories | first | replace: '-',' ' | capitalize }}</h3>
<ul>
{% capture category_name %}{{ page.categories | first }}{% endcapture %}
{% for post in site.categories.[category_name] limit:3 %}
<li><a href="{{ site.url }}{{ post.url }}">{{ post.title }}</a></li>
{% endfor %}
</ul>
17 changes: 17 additions & 0 deletions vitess.io/_includes/navigation-sliding.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<nav role="navigation" class="js-menu sliding-menu-content">
<ul class="menu-item">
{% for link in site.data.navigation %}<li>
{% unless link.url contains 'http' %}
{% assign domain = site.url %}
{% endunless %}
{% if link.image %}<a href="{{ domain }}{{ link.url }}"><img src="{{ site.url }}/images/{{ link.image }}" alt="teaser" class="teaser"></a>{% endif %}
<a href="{{ domain }}{{ link.url }}" class="title">{{ link.title }}</a>
{% if link.excerpt %}<p class="excerpt">{{ link.excerpt }}</p>{% endif %}
</li>{% endfor %}
</ul>
</nav>
<button type="button" class="js-menu-trigger sliding-menu-button menulines-button x2" role="button" aria-label="Toggle Navigation">
<span class="menulines"></span>
</button>

<div class="js-menu-screen menu-screen"></div>
11 changes: 11 additions & 0 deletions vitess.io/_includes/navigation.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
<ul class="menu-item">
<li class="home"><a href="/">{{ site.title }}</a></li>
{% for link in site.data.navigation %}
{% if link.url contains 'http' %}
{% assign domain = '' %}
{% else %}
{% assign domain = site.url %}
{% endif %}
<li><a href="{{ domain }}{{ link.url }}" {% if link.url contains 'http' %}target="_blank"{% endif %}>{{ link.title }}</a></li>
{% endfor %}
</ul>
Loading

0 comments on commit 2c0c8fc

Please sign in to comment.