eac_ruby_gems_utils 0.5.0 → 0.6.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 03ed15ab71663ad44165776c7ad4b0993af1a11b1886cb02118a46d31339f503
4
- data.tar.gz: fe497eb1240ae1190394dab833df4814965fe852ce3df4c451edf570c9a7a912
3
+ metadata.gz: 96ad40e228b3d95ed5f966a19d7449e860e1c6eddf0646492f7fc164bfaaf9b4
4
+ data.tar.gz: fa1d30195f503bf880d8dc9bb4f0063a550abd08bdef2d7c54e471c9039c87b2
5
5
  SHA512:
6
- metadata.gz: a7382fe287f7caeebeb731f0f33085aedaaa97185352088bb68e32fe7ac0443df1810e60562e9be16ebdcb9cfa982e2747654cf6a3ca191862784645dc0699de
7
- data.tar.gz: e3fa0d3c3533ef63aaa396d54b40e958c69e6a472c903811d7c7e89c33f565e787cfb75bca150542a268497c31739252f74eed53dd7295d2d519f0adbd474b0b
6
+ metadata.gz: 117390a61ccaf50fcc9853a2926726d7196151b56626b3482d595d8278f4e06e4073c47e73733553f5e5acb3ddf169bb9f152715e8c13761ba8e9a0d124176ab
7
+ data.tar.gz: b6a2673cd0d582eadf7ca565dbe59b5015ae960a548debf313c80a3522d346b8ff9ad1bcc001e9e74a66e03742ff1abeb1fa6c938f71c8b6951a96ade387ae88
@@ -42,12 +42,20 @@ module EacRubyGemsUtils
42
42
  root.basename.to_s
43
43
  end
44
44
 
45
+ def namespace_parts
46
+ name.split('-')
47
+ end
48
+
45
49
  def rake(*args)
46
50
  raise "File \"#{rakefile_path}\" does not exist" unless rakefile_path.exist?
47
51
 
48
52
  bundle('exec', 'rake', '--rakefile', rakefile_path, *args)
49
53
  end
50
54
 
55
+ def version
56
+ /VERSION\s*=\s*[\'\"]([^\'\"]+)[\'\"]/.if_match(version_file.read) { |m| m[1] }
57
+ end
58
+
51
59
  private
52
60
 
53
61
  def gemfile_path_uncached
@@ -65,5 +73,9 @@ module EacRubyGemsUtils
65
73
  def rakefile_path_uncached
66
74
  root.join('Rakefile')
67
75
  end
76
+
77
+ def version_file_uncached
78
+ root.join('lib', *namespace_parts, 'version.rb')
79
+ end
68
80
  end
69
81
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module EacRubyGemsUtils
4
- VERSION = '0.5.0'
4
+ VERSION = '0.6.0'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: eac_ruby_gems_utils
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.0
4
+ version: 0.6.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Esquilo Azul Company
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2020-06-14 00:00:00.000000000 Z
11
+ date: 2020-07-07 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: eac_ruby_utils