spark_engine 1.1.1 → 1.2.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/spark_engine/command/help.rb +23 -1
- data/lib/spark_engine/command.rb +13 -2
- data/lib/spark_engine/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 6c1bf0bedeafc9f534690e08affcc35d2ba33c11dbf8915c367c4af4b3aaa938
|
4
|
+
data.tar.gz: 87cbf4c2733d7929b16b778e7a36cb7814ae5dedad99ec693cdcceda73bc3af9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: fb3474519be01d0d2aaf032c5331bb96cb875632ecb3a9fe0ab09975bbba2a6f2015c9f08da37cb3d965cc170a6bb53818ac2c6222de3684d04c4a2a50f2a7e7
|
7
|
+
data.tar.gz: 33b684c431fedfd6de80f2b047e97240a6f2b89604f2a6b989d15e02f27691ec1b8fbc6ac3299c3087f70f4eb444a2b3f5265bb878ca195a26d9f055716275d4
|
@@ -21,7 +21,14 @@ Options:
|
|
21
21
|
end
|
22
22
|
|
23
23
|
def engine_commands
|
24
|
-
%w(help build watch server help gem:build gem:install gem:release)
|
24
|
+
list = %w(help build watch server help gem:build gem:install gem:release)
|
25
|
+
begin
|
26
|
+
gem 'bump'
|
27
|
+
list.concat %w(gem:bump:patch gem:bump:minor gem:bump:major)
|
28
|
+
rescue Gem::LoadError
|
29
|
+
end
|
30
|
+
|
31
|
+
list
|
25
32
|
end
|
26
33
|
|
27
34
|
def spark_commands
|
@@ -40,6 +47,9 @@ Options:
|
|
40
47
|
when 'gem:build'; gem_build
|
41
48
|
when 'gem:install'; gem_install
|
42
49
|
when 'gem:release'; gem_release
|
50
|
+
when 'gem:bump:patch'; gem_bump_patch
|
51
|
+
when 'gem:bump:minor'; gem_bump_minor
|
52
|
+
when 'gem:bump:major'; gem_bump_major
|
43
53
|
end
|
44
54
|
end
|
45
55
|
|
@@ -82,5 +92,17 @@ Options:
|
|
82
92
|
def gem_release
|
83
93
|
"gem:release # Build assets for production, build, and release gem to rubygems.org"
|
84
94
|
end
|
95
|
+
|
96
|
+
def gem_bump_patch
|
97
|
+
"gem:bump:patch # Upgrade v0.0.0 -> v0.0.1 and build assets"
|
98
|
+
end
|
99
|
+
|
100
|
+
def gem_bump_minor
|
101
|
+
"gem:bump:minor # Upgrade v0.0.0 -> v0.1.0 and build assets"
|
102
|
+
end
|
103
|
+
|
104
|
+
def gem_bump_major
|
105
|
+
"gem:bump:major # Upgrade v0.0.0 -> v1.0.0 and build assets"
|
106
|
+
end
|
85
107
|
end
|
86
108
|
end
|
data/lib/spark_engine/command.rb
CHANGED
@@ -33,6 +33,12 @@ module SparkEngine
|
|
33
33
|
from_root { gem_release }
|
34
34
|
when 'gem:tag'
|
35
35
|
from_root { gem_tag }
|
36
|
+
when 'gem:bump:patch'
|
37
|
+
from_root { gem_bump('patch') }
|
38
|
+
when 'gem:bump:minor'
|
39
|
+
from_root { gem_bump('minor') }
|
40
|
+
when 'gem:bump:major'
|
41
|
+
from_root { gem_bump('major') }
|
36
42
|
else
|
37
43
|
puts "Command `#{options[:command]}` not recognized"
|
38
44
|
end
|
@@ -67,11 +73,11 @@ module SparkEngine
|
|
67
73
|
@production = true
|
68
74
|
gem_build
|
69
75
|
spec = SparkEngine.plugin_spec
|
70
|
-
gem_file = "./pkg/#{spec.
|
76
|
+
gem_file = "./pkg/#{spec.name}-#{spec.version}.gem"
|
71
77
|
|
72
78
|
if File.exists?(gem_file)
|
73
79
|
system "git commit -m v#{spec.version}"
|
74
|
-
|
80
|
+
gem_tag
|
75
81
|
system "git push origin $(git rev-parse --abbrev-ref HEAD) --tag"
|
76
82
|
|
77
83
|
if key = ENV['RUBYGEMS_API_KEY']
|
@@ -85,6 +91,11 @@ module SparkEngine
|
|
85
91
|
end
|
86
92
|
end
|
87
93
|
|
94
|
+
def gem_bump(v)
|
95
|
+
system "bump #{v} --no-commit"
|
96
|
+
gem_build
|
97
|
+
end
|
98
|
+
|
88
99
|
def gem_tag
|
89
100
|
system "git tag v#{SparkEngine.plugin_spec.version}"
|
90
101
|
end
|
data/lib/spark_engine/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: spark_engine
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.
|
4
|
+
version: 1.2.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brandon Mathis
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2019-01-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: sass
|