jgd 1.8 → 1.9

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 25ecdbd1fc492987dce8c1e9cce64ebbb8707816
4
- data.tar.gz: 3570c8ea77131d5ee99cd47ab0a271eef2b09a3a
3
+ metadata.gz: cdfbd8bf3bcd5ea7fe4294ad94ecc2bd2ab30163
4
+ data.tar.gz: '0583594d8379d7cb8b1d1d5d9d6daa8ce78c1e72'
5
5
  SHA512:
6
- metadata.gz: 3dae444e96bdc5d6def375285f042fe29a0e82a07ea1b2fe1f61cbb3ec02c2fd8bc0ed559ca71156c1403d37ea3e5a45a69d7006b5fc865dbd5759f61b44fde3
7
- data.tar.gz: 4f6aa60be75659643f8c69162e5ceda556fc532032396ea26feb4d6c413f1b731f4abadd6a54aa1a384476823e2b6bd5bab24a1182ce89b4e35bbb0d09880235
6
+ metadata.gz: f2f2664ef647cb684fbd3c75777b51cda28323ae8dd1b6e03ad2d518b47285a0524cd6be905e274a1aca29b612debe925abf903b18fcc4f99a1c2839b7d52839
7
+ data.tar.gz: 18367a46d06590099f3d5e80e205c81862fa9e6d52b56d160a6d6608c5956dbe009ec44605aea204b7ad14d8097dbaefe89dd8c9c6d271b430c2eb5ce02cfe62
@@ -0,0 +1,5 @@
1
+ errors:
2
+ - yegor256@gmail.com
3
+ # alerts:
4
+ # github:
5
+ # - yegor256
data/.pdd ADDED
@@ -0,0 +1,7 @@
1
+ --source=.
2
+ --verbose
3
+ --exclude target/**/*
4
+ --exclude src/main/resources/images/**/*
5
+ --rule min-words:20
6
+ --rule min-estimate:15
7
+ --rule max-estimate:90
@@ -1,2 +1,18 @@
1
- MethodLength:
2
- Max: 30
1
+ AllCops:
2
+ Exclude:
3
+ - 'bin/**/*'
4
+ - 'assets/**/*'
5
+ DisplayCopNames: true
6
+
7
+ Lint/RescueException:
8
+ Enabled: false
9
+ Metrics/MethodLength:
10
+ Max: 50
11
+ Metrics/ClassLength:
12
+ Max: 150
13
+ Metrics/AbcSize:
14
+ Max: 60
15
+ Metrics/BlockLength:
16
+ Max: 50
17
+ Style/MultilineMethodCallIndentation:
18
+ Enabled: false
data/README.md CHANGED
@@ -7,7 +7,7 @@
7
7
  [![Dependency Status](https://gemnasium.com/yegor256/jekyll-github-deploy.svg)](https://gemnasium.com/yegor256/jekyll-github-deploy)
8
8
  [![Code Climate](http://img.shields.io/codeclimate/github/yegor256/jekyll-github-deploy.svg)](https://codeclimate.com/github/yegor256/jekyll-github-deploy)
9
9
 
10
- # What is jgd ?
10
+ ## What is jgd ?
11
11
 
12
12
  If you use some plugins with your Jekyll blog, chances are you can not
13
13
  have your blog generated by GitHub.
@@ -16,7 +16,7 @@ This is where jekyll-github-deploy (a.k.a. jgd) comes in: it will
16
16
  automatically build your Jekyll blog and push it to your gh-pages
17
17
  branch.
18
18
 
19
- # Installing
19
+ ## Installing
20
20
 
21
21
  It is assumed that your blog is in the home directory of your repo.
22
22
 
@@ -34,7 +34,19 @@ jgd
34
34
 
35
35
  Now your site is deployed to `gh-pages` branch of your repo. Done.
36
36
 
37
- # Production variables
37
+ ## Comand Line Options
38
+
39
+ Below is a list of all command line options.
40
+
41
+ | Option | Description |
42
+ | -------- | ----------- |
43
+ | `-u` or `--url` | The GitHub URL. Defaults to th URL of your current project. |
44
+ | `-b` or `--branch` | The branch to push your site to. Defaults to `gh-pages`. If the branch does not exist, it will be created. |
45
+ | `-r` or `--branch-from` | The source branch. Defaults to `master`. |
46
+ | `-c` or `--config` | Name of the optional deploy config file. See [Production variables](#production-variables) below for more information. |
47
+ | `-h` or `--help` | Displays a list of all options. |
48
+
49
+ ## Production variables
38
50
 
39
51
  If you need to have different values for your deployed blog, just add a
40
52
  `_config-deploy.yml` file in your project's root and you're set. Values
@@ -44,7 +56,15 @@ re-defined in `_config-deploy.yml` will override those defined in
44
56
  Typical usage includes changing site `url`, disable disqus or ga in
45
57
  development...., you name it.
46
58
 
47
- # Deploying with Travis
59
+ While `_config-deploy.yml` is the default, you may specify any config
60
+ file by using the `--config` command line option.
61
+
62
+ For example:
63
+ ```sh
64
+ $ jgd -c _config-deploy-develop.yml -r develop -b gh-pages-develop
65
+ ```
66
+
67
+ ## Deploying with Travis
48
68
 
49
69
  This is how I configure [my Jekyll blog](https://github.com/yegor256/blog)
50
70
  to be deployed automatically by [travis-ci](http://www.travis-ci.org):
@@ -81,6 +101,3 @@ script:
81
101
  ```
82
102
 
83
103
  Read also [this article](http://www.yegor256.com/2014/06/24/jekyll-github-deploy.html).
84
-
85
- PS. You can also specify target branch, with is `gh-pages` by default. Use
86
- `--branch` command line option.
@@ -6,6 +6,7 @@ set -o pipefail
6
6
  URL=$1
7
7
  BRANCH=$2
8
8
  BRANCH_FROM=$3
9
+ DEPLOY_CONFIG=$4
9
10
  SRC=$(pwd)
10
11
  TEMP=$(mktemp -d -t jgd-XXX)
11
12
  trap "rm -rf ${TEMP}" EXIT
@@ -21,8 +22,8 @@ cd "${CLONE}"
21
22
  echo -e "\nBuilding Jekyll site:"
22
23
  rm -rf _site
23
24
 
24
- if [ -r _config-deploy.yml ]; then
25
- jekyll build --config _config.yml,_config-deploy.yml
25
+ if [ -r ${DEPLOY_CONFIG} ]; then
26
+ jekyll build --config _config.yml,${DEPLOY_CONFIG}
26
27
  else
27
28
  jekyll build
28
29
  fi
data/bin/jgd CHANGED
@@ -11,12 +11,15 @@ Usage: jgd [options]
11
11
  opt :url, 'Github URL', type: String, default: ''
12
12
  opt :branch, 'Destination branch', type: String, default: 'gh-pages'
13
13
  opt :branch_from, 'Source branch', type: String, default: 'master'
14
+ opt :config, 'Deploy Config File', type: String, default: '_config-deploy.yml'
14
15
  end
15
16
 
16
17
  branch = opts[:branch]
17
18
  branch_from = opts[:branch_from]
19
+ config = opts[:config]
18
20
  fail 'branch can\'t be empty' if branch.empty?
19
21
  fail 'branch-from can\'t be empty' if branch_from.empty?
22
+ fail 'config can\'t be empty' if config.empty?
20
23
  url = opts[:url]
21
24
  url = `git config --get remote.origin.url`.strip if url.empty?
22
25
 
@@ -25,4 +28,4 @@ root = spec.gem_dir
25
28
  script = File.join(root, 'bash/deploy.sh')
26
29
 
27
30
  fail 'deployment failed, see log above' \
28
- unless system("#{script} #{url} #{branch} #{branch_from}")
31
+ unless system("#{script} #{url} #{branch} #{branch_from} #{config}")
@@ -8,7 +8,7 @@ Gem::Specification.new do |s|
8
8
  s.rubygems_version = '2.2.2'
9
9
  s.required_ruby_version = '>= 1.9.3'
10
10
  s.name = 'jgd'
11
- s.version = '1.8'
11
+ s.version = '1.9'
12
12
  s.license = 'MIT'
13
13
  s.summary = 'Jekyll Github Deploy'
14
14
  s.description = 'Automated deployment of your Jekyll blog to Github Pages'
@@ -16,8 +16,8 @@ Gem::Specification.new do |s|
16
16
  s.email = 'yegor@tpc2.com'
17
17
  s.homepage = 'http://github.com/yegor256/jekyll-github-deploy'
18
18
  s.files = `git ls-files`.split($RS)
19
- s.executables = s.files.grep(/^bin\//) { |f| File.basename(f) }
20
- s.test_files = s.files.grep(/^(test|spec|features)\//)
19
+ s.executables = s.files.grep(%r{^bin/}) { |f| File.basename(f) }
20
+ s.test_files = s.files.grep(%r{^(test|spec|features)/})
21
21
  s.rdoc_options = ['--charset=UTF-8']
22
22
  s.extra_rdoc_files = ['README.md', 'LICENSE.txt']
23
23
  s.add_runtime_dependency('trollop', '2.1.2')
@@ -25,7 +25,7 @@ Gem::Specification.new do |s|
25
25
  s.add_development_dependency 'coveralls', '0.7.0'
26
26
  s.add_development_dependency 'rdoc', '3.11'
27
27
  s.add_development_dependency 'minitest', '5.4.0'
28
- s.add_development_dependency 'rubocop', '0.24.1'
29
- s.add_development_dependency 'rubocop-rspec', '1.1.0'
28
+ s.add_development_dependency 'rubocop', '0.46.0'
29
+ s.add_development_dependency 'rubocop-rspec', '1.8.0'
30
30
  s.add_development_dependency 'rspec-rails', '2.13'
31
31
  end
data/test.sh CHANGED
@@ -14,7 +14,7 @@ git config user.name "Test"
14
14
  git commit -am 'initial commit'
15
15
  cd "${CWD}"
16
16
 
17
- ./bash/deploy.sh "${TMP}" gh-pages master
17
+ ./bash/deploy.sh "${TMP}" gh-pages master _some-other-config.yml
18
18
 
19
19
  cd "${TMP}"
20
20
  git checkout gh-pages
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: jgd
3
3
  version: !ruby/object:Gem::Version
4
- version: '1.8'
4
+ version: '1.9'
5
5
  platform: ruby
6
6
  authors:
7
7
  - Yegor Bugayenko
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-11-18 00:00:00.000000000 Z
11
+ date: 2017-05-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: trollop
@@ -86,28 +86,28 @@ dependencies:
86
86
  requirements:
87
87
  - - '='
88
88
  - !ruby/object:Gem::Version
89
- version: 0.24.1
89
+ version: 0.46.0
90
90
  type: :development
91
91
  prerelease: false
92
92
  version_requirements: !ruby/object:Gem::Requirement
93
93
  requirements:
94
94
  - - '='
95
95
  - !ruby/object:Gem::Version
96
- version: 0.24.1
96
+ version: 0.46.0
97
97
  - !ruby/object:Gem::Dependency
98
98
  name: rubocop-rspec
99
99
  requirement: !ruby/object:Gem::Requirement
100
100
  requirements:
101
101
  - - '='
102
102
  - !ruby/object:Gem::Version
103
- version: 1.1.0
103
+ version: 1.8.0
104
104
  type: :development
105
105
  prerelease: false
106
106
  version_requirements: !ruby/object:Gem::Requirement
107
107
  requirements:
108
108
  - - '='
109
109
  - !ruby/object:Gem::Version
110
- version: 1.1.0
110
+ version: 1.8.0
111
111
  - !ruby/object:Gem::Dependency
112
112
  name: rspec-rails
113
113
  requirement: !ruby/object:Gem::Requirement
@@ -131,13 +131,14 @@ extra_rdoc_files:
131
131
  - README.md
132
132
  - LICENSE.txt
133
133
  files:
134
+ - ".0pdd.yml"
134
135
  - ".gitignore"
136
+ - ".pdd"
135
137
  - ".rubocop.yml"
136
138
  - ".rultor.yml"
137
139
  - ".travis.yml"
138
140
  - Gemfile
139
141
  - LICENSE.txt
140
- - PUZZLES.md
141
142
  - README.md
142
143
  - Rakefile
143
144
  - TEAM.md
@@ -167,7 +168,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
167
168
  version: '0'
168
169
  requirements: []
169
170
  rubyforge_project:
170
- rubygems_version: 2.4.5.1
171
+ rubygems_version: 2.6.8
171
172
  signing_key:
172
173
  specification_version: 2
173
174
  summary: Jekyll Github Deploy
data/PUZZLES.md DELETED
@@ -1,4 +0,0 @@
1
- ## Puzzles
2
-
3
- There are 0 active puzzles (0 total):
4
-