pivotal-integration 1.6.0.1 → 1.6.0.2
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 +8 -8
- data/README.md +1 -7
- data/bin/pivotal +38 -13
- data/lib/pivotal-integration/command/finish.rb +4 -4
- data/lib/pivotal-integration/command/prepare-commit-msg.sh +1 -1
- data/lib/pivotal-integration/command/start.rb +1 -1
- data/lib/pivotal-integration/util/git.rb +1 -1
- data/lib/pivotal_integration.rb +1 -0
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
MDA0MzQ0NjdkMTNiN2ViMTViM2Y0MGU2YmYzN2M5Nzg4OGRmMjAxYw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
ZDI5NmVkMTI4YWRhZjk0M2M4NzgzODg2MTg3MDBlMTAzZDI5ZWY1OQ==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
NDc3OWNmMzYzMzg4YzMyOWE2NzQ3OGFjNjBmMWYxODNiZGIwMTQ5ZmRlNTk4
|
10
|
+
NDBhN2VmYjcwYTM4NzU4ZDFhOGVkYzBiZWI4NWMwNjIzNTcwNGJkOWU3OWFi
|
11
|
+
YjI5M2Y0NWViMGRmOTFlZTE2NGYyNTc5OTE2NThjZjkyZTAzMzA=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
YjEzODE1ODdkMTU4ODk0Nzc1NjdhMjQ3Y2YwZmVlZjQ4ZmY3YmIwNmRjYTZh
|
14
|
+
NDlhZTUyZjFiY2YwYzliMTgwYTVmZWI2ODg5NjBlOTk4ODk5NGUwMGFhMDMw
|
15
|
+
ZWRmN2U4M2RmMjIwZDlkODM1YWQwNjUwZmViYTcyNmUzNzk0MmE=
|
data/README.md
CHANGED
@@ -1,11 +1,5 @@
|
|
1
1
|
# Git Pivotal Tracker Integration
|
2
|
-
[
|
3
|
-
[](http://badge.fury.io/rb/git-pivotal-tracker-integration)
|
4
|
-
[](http://gemnasium.com/nebhale/git-pivotal-tracker-integration)
|
5
|
-
[](https://codeclimate.com/github/nebhale/git-pivotal-tracker-integration)
|
6
|
-
|
7
|
-
|
8
|
-
`pivotal-integration` provides a set of additional Git commands to help developers when working with [Pivotal Tracker][pivotal-tracker].
|
2
|
+
`pivotal-integration` provides a set of additional Git commands to help developers when working with [Pivotal Tracker][pivotal-tracker]. It is based on and extended from [git-pivotal-tracker-integration](https://github.com/nebhale/git-pivotal-tracker-integration) by Ben Hale.
|
9
3
|
|
10
4
|
[pivotal-tracker]: http://www.pivotaltracker.com
|
11
5
|
|
data/bin/pivotal
CHANGED
@@ -33,7 +33,7 @@ def print_command_help(commands)
|
|
33
33
|
end
|
34
34
|
|
35
35
|
def show_help
|
36
|
-
puts "Usage:
|
36
|
+
puts "Usage: pivotal [--help] <command> [<args>]"
|
37
37
|
puts
|
38
38
|
|
39
39
|
main_commands = COMMANDS.select{ |c| %w(start finish new).include? c.name.demodulize.downcase }
|
@@ -48,21 +48,46 @@ def show_help
|
|
48
48
|
end
|
49
49
|
|
50
50
|
begin
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
51
|
+
if COMMAND_NAMES.include?(ARGV.first.try(:downcase))
|
52
|
+
command = ARGV.shift.downcase
|
53
|
+
|
54
|
+
options = {}
|
55
|
+
optparse = OptionParser.new do |opts|
|
56
|
+
opts.on('-h', '--help') do
|
57
|
+
show_help
|
58
|
+
exit
|
59
|
+
end
|
60
|
+
|
61
|
+
opts.on('-S', '--story ID') do |id|
|
62
|
+
options[:story_id] = id
|
63
|
+
end
|
64
|
+
|
65
|
+
if command == 'start'
|
66
|
+
opts.on('--use-current') do
|
67
|
+
options[:use_current] = true
|
68
|
+
end
|
69
|
+
end
|
57
70
|
|
58
|
-
|
59
|
-
|
71
|
+
if command == 'finish'
|
72
|
+
opts.on('--pull-request') do
|
73
|
+
options[:pull_request] = true
|
74
|
+
end
|
75
|
+
|
76
|
+
opts.on('--no-complete') do
|
77
|
+
options[:no_complete] = true
|
78
|
+
end
|
79
|
+
|
80
|
+
opts.on('--no-delete') do
|
81
|
+
options[:no_delete] = true
|
82
|
+
end
|
83
|
+
|
84
|
+
opts.on('--no-merge') do
|
85
|
+
options[:no_merge] = true
|
86
|
+
end
|
87
|
+
end
|
60
88
|
end
|
61
|
-
|
62
|
-
optparse.parse!
|
89
|
+
optparse.parse!
|
63
90
|
|
64
|
-
if COMMAND_NAMES.include?(ARGV.first.try(:downcase))
|
65
|
-
command = ARGV.shift
|
66
91
|
command_class = PivotalIntegration::Command.const_get(command.classify)
|
67
92
|
command_class.new(options).run(*ARGV)
|
68
93
|
|
@@ -27,10 +27,10 @@ class PivotalIntegration::Command::Finish < PivotalIntegration::Command::Base
|
|
27
27
|
#
|
28
28
|
# @return [void]
|
29
29
|
def run(*arguments)
|
30
|
-
no_complete =
|
31
|
-
no_delete =
|
32
|
-
no_merge =
|
33
|
-
pull_request =
|
30
|
+
no_complete = @options.fetch(:no_complete, false)
|
31
|
+
no_delete = @options.fetch(:no_delete, false)
|
32
|
+
no_merge = @options.fetch(:no_merge, false)
|
33
|
+
pull_request = @options.fetch(:pull_request, false) || PivotalIntegration::Util::Git.finish_mode == :pull_request
|
34
34
|
|
35
35
|
if pull_request
|
36
36
|
PivotalIntegration::Util::Git.push PivotalIntegration::Util::Git.branch_name
|
@@ -33,7 +33,7 @@ class PivotalIntegration::Command::Start < PivotalIntegration::Command::Base
|
|
33
33
|
# @return [void]
|
34
34
|
def run(*arguments)
|
35
35
|
filter = arguments.first
|
36
|
-
use_current_branch =
|
36
|
+
use_current_branch = @options.fetch(:use_current, false)
|
37
37
|
|
38
38
|
if filter == 'new'
|
39
39
|
arguments.shift
|
@@ -176,7 +176,7 @@ class PivotalIntegration::Util::Git
|
|
176
176
|
when :web
|
177
177
|
# Open the PR editor in a web browser
|
178
178
|
repo = get_config('remote.origin.url')[/(?<=git@github.com:)[a-z0-9_-]+\/[a-z0-9_-]+/]
|
179
|
-
title = CGI::escape("
|
179
|
+
title = CGI::escape("[##{story.id}] #{story.name}]")
|
180
180
|
Launchy.open "https://github.com/#{repo}/compare/#{branch_name}?expand=1&pull_request[title]=#{title}"
|
181
181
|
|
182
182
|
else
|
data/lib/pivotal_integration.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pivotal-integration
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.6.0.
|
4
|
+
version: 1.6.0.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Ben Hale
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2014-03-
|
12
|
+
date: 2014-03-27 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
type: :runtime
|