rake_commit 1.1.0 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 1b9f0d0536a6adc348294e3f4688fa2e99a6457f
4
- data.tar.gz: dcf39345cbf7250a4334b1ceee434f6cbabe50a6
3
+ metadata.gz: 8ea1f63f9545e05c6ac0a8ea9da6c7bc97748667
4
+ data.tar.gz: 7850c7d442419a515964e4e47cbcff9f64d85cbc
5
5
  SHA512:
6
- metadata.gz: c785b500149d04b184feac3458d6fd684b35bd157f4e0432213e48dcc1358fee7fe4d786b89107c697b705b92f63e237759ee4d91913d7ba158f1ca1cb256a64
7
- data.tar.gz: 03fd8ef87657c12ef3ef413afc8ae454eac7c5731319095663548b0585717ee3442912e4028eb37ac3553d1714046e2f51c96532430ec0cbcd4e957c40f8ca2a
6
+ metadata.gz: c5241e7795d91d35c00ed80c63bc78e96682c4be76fc7944d00f641e4da72a1af2ffe1147b23b2f1713fe8e64239e12d0c641906ca6527ecebc4eb1d08521cef
7
+ data.tar.gz: 910b3d3d580b38e8f13f4287d1dac46ff04e1b91f97521ebd41c0200cdebb9d26fb9f4261324f1bc42df26c15e6fccfb6f055ea3fcc1ba50ba0279df96855de8
@@ -18,7 +18,8 @@ module RakeCommit
18
18
  options = {
19
19
  :collapse_commits => true,
20
20
  :incremental => false,
21
- :prompt_exclusions => []
21
+ :prompt_exclusions => [],
22
+ :build_command => "rake"
22
23
  }
23
24
 
24
25
  if File.exists?(".rake_commit")
@@ -30,7 +31,7 @@ module RakeCommit
30
31
  if git_svn?
31
32
  RakeCommit::GitSvn.new(options[:prompt_exclusions]).commit
32
33
  elsif git?
33
- RakeCommit::Git.new(options[:collapse_commits], options[:rebase_only], options[:incremental], options[:prompt_exclusions], options[:precommit]).commit
34
+ RakeCommit::Git.new(options[:build_command], options[:collapse_commits], options[:rebase_only], options[:incremental], options[:prompt_exclusions], options[:precommit]).commit
34
35
  else
35
36
  RakeCommit::Svn.new(options[:prompt_exclusions]).commit
36
37
  end
@@ -59,6 +60,9 @@ module RakeCommit
59
60
  opts.on("-p", "--precommit SCRIPT", "command to run before commiting changes") do |command|
60
61
  options[:precommit] = command
61
62
  end
63
+ opts.on("-b", "--build-command SCRIPT", "the command that verifies the commit, defaults to rake") do |command|
64
+ options[:build_command] = command
65
+ end
62
66
  end
63
67
 
64
68
  parser.parse(args)
@@ -3,7 +3,8 @@ require 'shellwords'
3
3
  module RakeCommit
4
4
  class Git
5
5
 
6
- def initialize(collapse_commits = true, rebase_only = false, incremental = false, prompt_exclusions = [], precommit = nil)
6
+ def initialize(build_command, collapse_commits = true, rebase_only = false, incremental = false, prompt_exclusions = [], precommit = nil)
7
+ @build_command = build_command
7
8
  @collapse_commits = collapse_commits
8
9
  @rebase_only = rebase_only
9
10
  @incremental = incremental
@@ -16,7 +17,7 @@ module RakeCommit
16
17
  incremental_commit
17
18
  elsif rebase_in_progress?
18
19
  rebase_continue
19
- RakeCommit::Shell.system("rake")
20
+ RakeCommit::Shell.system(@build_command)
20
21
  push
21
22
  else
22
23
  if collapse_git_commits?
@@ -26,7 +27,7 @@ module RakeCommit
26
27
  incremental_commit unless nothing_to_commit?
27
28
  pull_rebase rescue return false
28
29
  end
29
- RakeCommit::Shell.system("rake")
30
+ RakeCommit::Shell.system(@build_command)
30
31
  push
31
32
  end
32
33
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rake_commit
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.0
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Paul Gross
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-07-19 00:00:00.000000000 Z
11
+ date: 2015-03-18 00:00:00.000000000 Z
12
12
  dependencies: []
13
13
  description: See http://github.com/pgr0ss/rake_commit
14
14
  email: pgross@gmail.com
@@ -49,7 +49,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
49
49
  version: '0'
50
50
  requirements: []
51
51
  rubyforge_project: rake_commit
52
- rubygems_version: 2.2.2
52
+ rubygems_version: 2.4.6
53
53
  signing_key:
54
54
  specification_version: 4
55
55
  summary: A gem which helps with checking in code