diff --git a/Gemfile b/Gemfile index 7b98eda..37f5eaa 100644 --- a/Gemfile +++ b/Gemfile @@ -1,3 +1,2 @@ -# A sample Gemfile -source "https://rubygems.org" -gem 'github-pages' \ No newline at end of file +source 'https://rubygems.org' +gem 'github-pages', group: :jekyll_plugins diff --git a/README.md b/README.md index 7af2b16..00995cb 100644 --- a/README.md +++ b/README.md @@ -1,26 +1,64 @@ -# WP-API Documentation Site -This repository is the source for -[WP-API's documentation](http://wp-api.github.io). We're working on making this -documentation [the best in the world][gh-1], but we're not there yet! +# WP REST API Documentation Site -[gh-1]: https://github.com/WP-API/WP-API.github.io/issues/1 +This repository is the source for [wp-api.org][gh-1]. It powers documentation for the +[WP REST API (WP-API)][gh-2] plugin. We are working on making this documentation +the [best in the world][gh-3], but we're not there yet! -## Running locally +**[Read the Docs ☞][gh-1]** + +[gh-1]: http://wp-api.org +[gh-2]: https://github.com/WP-API/WP-API +[gh-3]: https://github.com/WP-API/WP-API.github.io/issues/1 + + +## Running Locally + +This site is hosted on Github pages and powered by Jekyll. + + ```bash + bundle install + bundle exec jekyll serve -w + ``` + +then visit `localhost:4000` in your favorite browser. You can learn more about +using Jekyll and Github pages from their [documentation](https://help.github.com/articles/using-jekyll-with-pages/). + +### Using Vagrant We recommend using Vagrant. Here's how you do that: -```bash -$ vagrant up -$ vagrant ssh - -# Following commands are now executed on the box -# These install everything you need -$ cd /vagrant -$ sudo apt-get update -$ sudo apt-get install ruby1.9.3 rubygems make -$ sudo gem install bundler -$ bundle install - -# To run the site: -$ jekyll serve -``` + ```bash + $ vagrant up + $ vagrant ssh + + # Following commands are now executed on the box + # These install everything you need + $ cd /vagrant + $ sudo apt-get update + $ sudo apt-get install ruby1.9.3 rubygems make + $ sudo gem install bundler + $ bundle install + + # To run the site: + $ jekyll serve + ``` + + +## Style Guide + +This guide is a limited implementation of [Carwin's Markdown Style Guidelines](https://github.com/carwin/markdown-styleguide). + +- Wrap all lines at 80 characters. +- Denote **bold** text using the asterisk format: `**bold text**`. +- Denote _italic_ text using the underscore format: `_emphasized text_`. +- Force a linebreak by ending a line with two spaces, no more. +- Header text must use the `atx-style` with no closing `#` character. +- Include a space between the `#` and the text of the Header. +- List item lines exceeding 80 characters should, when wrapped, align + vertically with the beginning of the preceding line's text. +- **Inline code** must use single backticks and must not have spaces between + the backtick characters and the code. +- **Fenced code blocks** must be preceded and followed by a newline. +- When used inside _list items_, **fenced code blocks** must be indented as if + they were one level deeper that the list item that contains them. + diff --git a/_config.yml b/_config.yml index 02941f8..413e2cb 100644 --- a/_config.yml +++ b/_config.yml @@ -1,5 +1,9 @@ baseurl: / -pygments: true +encoding: utf-8 +highlighter: pygments markdown: kramdown kramdown: input: GFM + line_width: 80 +gems: + - jekyll-redirect-from diff --git a/_includes/header.html b/_includes/header.html index 5996781..80399c9 100644 --- a/_includes/header.html +++ b/_includes/header.html @@ -3,14 +3,16 @@
This site is for the legacy version (v1) of the API. View Version 2 Documentation
or continue to the Version 1 Documentation.
+