pr-daikou 0.0.3 → 0.1.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/pr-daikou/cli.rb +11 -11
- data/lib/pr-daikou/host/github.rb +1 -3
- data/lib/pr-daikou/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3a828cfb269e3369109142bc49697240bb9695aee9b7c7d078a49162d5f37bfc
|
4
|
+
data.tar.gz: d63c404811c00cab36fb9b23adaee885e31b0cf84312d129b126293118414ad3
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f01e9120952b6c4da84158b8f8d05b87617a486fed70c2d2d40d1c0679d41ca9ba5ddba67c69d57c1d97c42b8cc879127db803274362fae1aff72a247cf2b50b
|
7
|
+
data.tar.gz: ccb734f0a70c1f48792f83855b0d62fb484f32d8933bc1026fd44a073a46e9d029240e84906066671d065c450b4caf14dd5a67edefc19ba36644f02d61373a63
|
data/lib/pr-daikou/cli.rb
CHANGED
@@ -28,18 +28,18 @@ module PRDaikou
|
|
28
28
|
|
29
29
|
private
|
30
30
|
|
31
|
-
|
32
|
-
|
33
|
-
|
31
|
+
def parser
|
32
|
+
@parser ||= OptionParser.new do |opt|
|
33
|
+
opt.banner = 'Usage: pr-daikou [options]'
|
34
34
|
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
end
|
35
|
+
opt.on('--email EMAIL', "git committed user email, default: #{@options[:email]}") {|v| @options[:email] = v }
|
36
|
+
opt.on('--name NAME', "git committed user name, default: #{@options[:name]}") {|v| @options[:name] = v }
|
37
|
+
opt.on('-T', '--title TITLE', "pull request title, default: #{@options[:title]} [at Mon Jan 1 12:34:56 UTC 2017]") {|v| @options[:title] = v }
|
38
|
+
opt.on('--description DESC', "pull request description, default: #{@options[:description]}") {|v| @options[:description] = v }
|
39
|
+
opt.on('-m', '--commit MESSAGE', "add git commit message, default: #{@options[:commit]}") {|v| @options[:commit] = v }
|
40
|
+
opt.on('-b', '--base BRANCH', "pull request base branch, default: #{@options[:base]}") {|v| @options[:base] = v }
|
41
|
+
opt.on('-t', '--topic BRANCH', "create new branch, default: #{@options[:topic]}_[20170101123456.000]") {|v| @options[:topic] = v }
|
43
42
|
end
|
43
|
+
end
|
44
44
|
end
|
45
45
|
end
|
@@ -8,11 +8,9 @@ module PRDaikou
|
|
8
8
|
module_function
|
9
9
|
|
10
10
|
def create_branch(email, username, new_branch, commit_message)
|
11
|
-
`git config --local user.email "#{email}"`
|
12
|
-
`git config --local user.name "#{username}"`
|
13
11
|
`git checkout -b #{new_branch}`
|
14
12
|
`git add .`
|
15
|
-
`git commit -m "#{commit_message}"`
|
13
|
+
`GIT_AUTHOR_NAME=#{username} GIT_AUTHOR_EMAIL=#{email} GIT_COMMITTER_NAME=#{username} GIT_COMMITTER_EMAIL=#{email} git commit -m "#{commit_message}"`
|
16
14
|
`git push #{repository_url} #{new_branch}`
|
17
15
|
end
|
18
16
|
|
data/lib/pr-daikou/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pr-daikou
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0
|
4
|
+
version: 0.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- rvillage
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-
|
11
|
+
date: 2018-06-01 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -60,7 +60,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
60
60
|
version: '0'
|
61
61
|
requirements: []
|
62
62
|
rubyforge_project:
|
63
|
-
rubygems_version: 2.7.
|
63
|
+
rubygems_version: 2.7.7
|
64
64
|
signing_key:
|
65
65
|
specification_version: 4
|
66
66
|
summary: Create GitHub PullRequest of code changes in CI Service
|