diff --git a/site/docs/configuration.md b/site/docs/configuration.md index 31bf7048..c94656db 100644 --- a/site/docs/configuration.md +++ b/site/docs/configuration.md @@ -281,6 +281,7 @@ layouts: ./_layouts include: ['.htaccess'] exclude: [] keep_files: ['.git','.svn'] +gems: [] timezone: nil encoding: nil diff --git a/site/docs/plugins.md b/site/docs/plugins.md index a61d903e..c9e0c5ad 100644 --- a/site/docs/plugins.md +++ b/site/docs/plugins.md @@ -25,9 +25,27 @@ having to modify the Jekyll source itself. ## Installing a plugin -In your site source root, make a `_plugins` directory. Place your plugins here. -Any file ending in `*.rb` inside this directory will be loaded before Jekyll -generates your site. +You have 2 options for installing plugins: + +1. In your site source root, make a `_plugins` directory. Place your plugins here. + Any file ending in `*.rb` inside this directory will be loaded before Jekyll + generates your site. +2. In your `_config.yml` file, add a new array with the key `gems` and the values + of the gem names of the plugins you'd like to use. An example: + + gems: [jekyll-test-plugin, jekyll-jsonify, jekyll-assets] + # This will require each of these gems automatically. + +
+
+ _plugins and gems + can be used simultaneously +
+

+ You may use both of the aforementioned plugin options simultaneously in the + same site if you so choose. Use of one does not restrict the use of the other +

+
In general, plugins you make will fall into one of three categories: @@ -67,7 +85,7 @@ module Reading class Generator < Jekyll::Generator def generate(site) ongoing, done = Book.all.partition(&:ongoing?) - + reading = site.pages.detect {|page| page.name == 'reading.html'} reading.data['ongoing'] = ongoing reading.data['done'] = done @@ -394,7 +412,7 @@ You can find a few useful plugins at the following locations: - [ArchiveGenerator by Ilkka Laukkanen](https://gist.github.com/707909): Uses [this archive page](https://gist.github.com/707020) to generate archives. - [LESS.js Generator by Andy Fowler](https://gist.github.com/642739): Renders LESS.js files during generation. -- [Version Reporter by Blake Smith](https://gist.github.com/449491): Creates a version.html file containing the Jekyll version. +- [Version Reporter by Blake Smith](https://gist.github.com/449491): Creates a version.html file containing the Jekyll version. - [Sitemap.xml Generator by Michael Levin](https://github.com/kinnetica/jekyll-plugins): Generates a sitemap.xml file by traversing all of the available posts and pages. - [Full-text search by Pascal Widdershoven](https://github.com/PascalW/jekyll_indextank): Adds full-text search to your Jekyll site with a plugin and a bit of JavaScript. - [AliasGenerator by Thomas Mango](https://github.com/tsmango/jekyll_alias_generator): Generates redirect pages for posts when an alias is specified in the YAML Front Matter.