README.md in jgd-1.8 vs README.md in jgd-1.9

- old
+ new

@@ -5,20 +5,20 @@ [![Build Status](https://travis-ci.org/yegor256/jekyll-github-deploy.svg)](https://travis-ci.org/yegor256/jekyll-github-deploy) [![Gem Version](https://badge.fury.io/rb/jgd.svg)](http://badge.fury.io/rb/jgd) [![Dependency Status](https://gemnasium.com/yegor256/jekyll-github-deploy.svg)](https://gemnasium.com/yegor256/jekyll-github-deploy) [![Code Climate](http://img.shields.io/codeclimate/github/yegor256/jekyll-github-deploy.svg)](https://codeclimate.com/github/yegor256/jekyll-github-deploy) -# What is jgd ? +## What is jgd ? If you use some plugins with your Jekyll blog, chances are you can not have your blog generated by GitHub. This is where jekyll-github-deploy (a.k.a. jgd) comes in: it will automatically build your Jekyll blog and push it to your gh-pages branch. -# Installing +## Installing It is assumed that your blog is in the home directory of your repo. Install it first: @@ -32,22 +32,42 @@ jgd ``` Now your site is deployed to `gh-pages` branch of your repo. Done. -# Production variables +## Comand Line Options +Below is a list of all command line options. + +| Option | Description | +| -------- | ----------- | +| `-u` or `--url` | The GitHub URL. Defaults to th URL of your current project. | +| `-b` or `--branch` | The branch to push your site to. Defaults to `gh-pages`. If the branch does not exist, it will be created. | +| `-r` or `--branch-from` | The source branch. Defaults to `master`. | +| `-c` or `--config` | Name of the optional deploy config file. See [Production variables](#production-variables) below for more information. | +| `-h` or `--help` | Displays a list of all options. | + +## Production variables + If you need to have different values for your deployed blog, just add a `_config-deploy.yml` file in your project's root and you're set. Values re-defined in `_config-deploy.yml` will override those defined in `_config.yml`. Typical usage includes changing site `url`, disable disqus or ga in development...., you name it. -# Deploying with Travis +While `_config-deploy.yml` is the default, you may specify any config +file by using the `--config` command line option. +For example: +```sh +$ jgd -c _config-deploy-develop.yml -r develop -b gh-pages-develop +``` + +## Deploying with Travis + This is how I configure [my Jekyll blog](https://github.com/yegor256/blog) to be deployed automatically by [travis-ci](http://www.travis-ci.org): ```yaml branches: @@ -79,8 +99,5 @@ script: - jgd -u git@github.com:yegor256/blog.git ``` Read also [this article](http://www.yegor256.com/2014/06/24/jekyll-github-deploy.html). - -PS. You can also specify target branch, with is `gh-pages` by default. Use -`--branch` command line option.