autogitc 0.3.0 → 0.3.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/autogitc +13 -6
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6172f9a5a53368d7742aea250e9580e5f0e6b04dc74a3d682fe664f8aa091b25
|
4
|
+
data.tar.gz: b6a4634d9908e2092657c9a33b58e987a6245a91715d185bb1a7957d9a6a7297
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 836baef144d43e4ffef6f209ab39dd8c33f7482929c3568eb9ecb2e40fc4bcd883b2f8a825491c1b8d3bcc38cbbbc1d2bde5386f294f06b22452bc95e17fec1d
|
7
|
+
data.tar.gz: 9daba95131c266b4dcca3d536424d0d914c1d16bd9af79f108e9ca433c305bf1cf1ecf3c4fee04fd9c648b79f4c45525bd1f2c2e2df7208ddf19eae7cb5169ad
|
data/bin/autogitc
CHANGED
@@ -3,6 +3,12 @@ require 'bundler/setup'
|
|
3
3
|
require_relative '../lib/commit_generator'
|
4
4
|
require_relative '../lib/pr_template_generator'
|
5
5
|
|
6
|
+
if ARGV.include?('--version')
|
7
|
+
gemspec = Gem::Specification.load('autogitc.gemspec')
|
8
|
+
puts "autogitc version #{gemspec.version}"
|
9
|
+
exit
|
10
|
+
end
|
11
|
+
|
6
12
|
if ARGV.include?('pr')
|
7
13
|
base_branch_arg = ARGV.find { |arg| arg.start_with?('--base=') }
|
8
14
|
base_branch = base_branch_arg ? base_branch_arg.split('=').last : 'main'
|
@@ -10,10 +16,11 @@ if ARGV.include?('pr')
|
|
10
16
|
|
11
17
|
puts 'Running PR template generator...'
|
12
18
|
PrTemplateGenerator.main(base_branch: base_branch)
|
13
|
-
|
14
|
-
no_commit = ARGV.include?('--nocommit') || ARGV.include?('--nc')
|
15
|
-
must_have_text = ARGV.find { |arg| arg.start_with?('--text=') }&.split('=')&.last
|
16
|
-
|
17
|
-
puts 'Running autogitc...'
|
18
|
-
CommitGenerator.main(no_commit: no_commit, must_have_text: must_have_text)
|
19
|
+
exit
|
19
20
|
end
|
21
|
+
|
22
|
+
no_commit = ARGV.include?('--nocommit') || ARGV.include?('--nc')
|
23
|
+
must_have_text = ARGV.find { |arg| arg.start_with?('--text=') }&.split('=')&.last
|
24
|
+
|
25
|
+
puts 'Running autogitc...'
|
26
|
+
CommitGenerator.main(no_commit: no_commit, must_have_text: must_have_text)
|