get_env 0.1.4 → 0.2.0.pre

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: 2f2f663152b27c3a911a38ea2ab930a4035f808036c6fc721e5374993a668ccb
4
- data.tar.gz: 6f6db938e4c6f1e695d18c0e87914231c8c55e481102e719dfb82a1933e3e914
3
+ metadata.gz: 5ae6002e2491ed021f13b2c30998401bb8764b02b80a35244c86f4fcc3487f06
4
+ data.tar.gz: ce08c98b6eb9529128676804e71c2dd0958c7dcc7cfcb9e586c01eb0fb53ff1a
5
5
  SHA512:
6
- metadata.gz: 0fd52dd3d9e3c1dd5f6ab569cb2e2b4483bf5b3d88c5a9ddee3072f8eedb946f20b1846a916b64728a639f084bb9465857d4a1e5eae08d6a9289649b3c29e135
7
- data.tar.gz: 1b39d837f70ca650f69d9ea631497208619303bdb9c75cb1d895ac2f68dc958ceb3f513b0590c2e135e193f95e49db14853fe4c4003495b47d7257606b87d2d8
6
+ metadata.gz: 36fddc113a9ca9f6aa6d7e88838a0c314c17193e9509c7abcd2809bf910cd6e71ff42fb60c274b237f9e5432fc90a9fce3cd7e5badede00b4f13560a77449ed5
7
+ data.tar.gz: 0b59cbdab87a82efc2f1657a94e2bf6cb8468e4f0df87f5dd8fe59dc94337b2f5a9e023ff77a675a8fa9c0694b77a04de91d05d0bbe7a240839f3c8a71682aa1
@@ -1,9 +1,11 @@
1
1
  # frozen_string_literal: true
2
- require "get_env/version"
2
+
3
+ require 'get_env/version'
3
4
 
4
5
  module GetEnv
5
6
  def self.[](key)
6
7
  return nil if key.nil?
8
+
7
9
  v = ENV[key].to_i
8
10
  return v if v.to_s == ENV[key]
9
11
 
@@ -19,7 +21,7 @@ module GetEnv
19
21
  def self.fetch(key, default = nil)
20
22
  if ENV.has_key?(key)
21
23
  self[key]
22
- elsif default != nil
24
+ elsif !default.nil?
23
25
  default
24
26
  elsif block_given?
25
27
  yield
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module GetEnv
4
- VERSION = '0.1.4'
4
+ VERSION = '0.2.0.pre'
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: get_env
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.4
4
+ version: 0.2.0.pre
5
5
  platform: ruby
6
6
  authors:
7
7
  - Simon Mathieu
@@ -10,7 +10,7 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2020-03-02 00:00:00.000000000 Z
13
+ date: 2020-05-25 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: bundler
@@ -68,6 +68,20 @@ dependencies:
68
68
  - - ">="
69
69
  - !ruby/object:Gem::Version
70
70
  version: '0'
71
+ - !ruby/object:Gem::Dependency
72
+ name: rubocop
73
+ requirement: !ruby/object:Gem::Requirement
74
+ requirements:
75
+ - - ">="
76
+ - !ruby/object:Gem::Version
77
+ version: '0'
78
+ type: :development
79
+ prerelease: false
80
+ version_requirements: !ruby/object:Gem::Requirement
81
+ requirements:
82
+ - - ">="
83
+ - !ruby/object:Gem::Version
84
+ version: '0'
71
85
  description: Read values from ENV in a reasonable way
72
86
  email:
73
87
  - bartek@rainforestqa.com
@@ -93,9 +107,9 @@ required_ruby_version: !ruby/object:Gem::Requirement
93
107
  version: '0'
94
108
  required_rubygems_version: !ruby/object:Gem::Requirement
95
109
  requirements:
96
- - - ">="
110
+ - - ">"
97
111
  - !ruby/object:Gem::Version
98
- version: '0'
112
+ version: 1.3.1
99
113
  requirements: []
100
114
  rubygems_version: 3.0.3
101
115
  signing_key: