config 4.0.0 → 5.0.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +25 -0
- data/CONTRIBUTING.md +9 -3
- data/README.md +0 -1
- data/config.gemspec +3 -3
- data/lib/config/options.rb +3 -3
- data/lib/config/sources/yaml_source.rb +4 -4
- data/lib/config/version.rb +1 -1
- data/lib/config.rb +2 -2
- data/lib/generators/config/install_generator.rb +1 -1
- metadata +29 -15
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 63588fb0e3226125aacd3d3e8223a61b8bbe3b8dad14388fd6c4e7389a1fbebb
|
4
|
+
data.tar.gz: 63db33abec5829b54e5e41ee328891556ae63dfd27bdf04048592ac945ed7a8c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3761476e2956deb7423c360d041c622de50cf79fc763271fa2dd8754f104408579fdddafe735044f115cc39100ba21de725ce7d2c19f9d1e178aaddb74487b42
|
7
|
+
data.tar.gz: af8a9adfd80ce42580e18097ac108796e3c3e52ed7068348b7aff8e4050557e273a036728d4898891b118e5ae6b6909e283593a1b3630ec9f22b504592dd82d1
|
data/CHANGELOG.md
CHANGED
@@ -1,5 +1,30 @@
|
|
1
1
|
# Changelog
|
2
2
|
|
3
|
+
## 5.0.0
|
4
|
+
|
5
|
+
### BREAKING CHANGES
|
6
|
+
|
7
|
+
* No longer load `deep_merge`'s monkey patch for `Hash#deep_merge` and `Hash#deep_merge!` ([#342](https://github.com/rubyconfig/config/pull/342)). If you rely on those methods and are not using Rails / Active Support, you can load the monkey patch via `require 'deep_merge/deep_merge_hash'`. This change fixes Rails 7.x support.
|
8
|
+
|
9
|
+
## 4.2.1
|
10
|
+
|
11
|
+
### Bug fixes
|
12
|
+
|
13
|
+
* Address edge case with `table` config param ([#339](https://github.com/rubyconfig/config/pull/339))
|
14
|
+
|
15
|
+
## 4.2.0
|
16
|
+
|
17
|
+
### Bug fixes
|
18
|
+
|
19
|
+
* Remove use of method `File.exists?` to fix use in Ruby 3.0 ([#318](https://github.com/rubyconfig/config/pull/318))
|
20
|
+
|
21
|
+
## 4.1.0
|
22
|
+
|
23
|
+
### Bug fixes
|
24
|
+
|
25
|
+
* Only load `Railtie` integration if `Rails::Railtie` is defined ([#319](https://github.com/rubyconfig/config/pull/319))
|
26
|
+
* Fix indentation warning in Ruby 3.1 ([#322](https://github.com/rubyconfig/config/pull/322))
|
27
|
+
|
3
28
|
## 4.0.0
|
4
29
|
|
5
30
|
### BREAKING CHANGES
|
data/CONTRIBUTING.md
CHANGED
@@ -3,7 +3,7 @@
|
|
3
3
|
Install appraisal
|
4
4
|
|
5
5
|
```bash
|
6
|
-
gem install bundler
|
6
|
+
gem install bundler
|
7
7
|
gem install appraisal
|
8
8
|
```
|
9
9
|
|
@@ -16,13 +16,19 @@ bundle install
|
|
16
16
|
Bootstrap
|
17
17
|
|
18
18
|
```bash
|
19
|
-
appraisal install
|
19
|
+
bundle exec appraisal install
|
20
|
+
```
|
21
|
+
|
22
|
+
If you need to create new test app for specific rails version
|
23
|
+
|
24
|
+
```bash
|
25
|
+
bundle exec appraisal rails-7.0 rails new spec/app/rails_7.0
|
20
26
|
```
|
21
27
|
|
22
28
|
Run the test suite:
|
23
29
|
|
24
30
|
```bash
|
25
|
-
appraisal rspec
|
31
|
+
bundle exec appraisal rspec
|
26
32
|
```
|
27
33
|
|
28
34
|
If you modified any of the documentation files verify their format:
|
data/README.md
CHANGED
@@ -2,7 +2,6 @@
|
|
2
2
|
|
3
3
|
[![Version](https://img.shields.io/gem/v/config)](https://rubygems.org/gems/config)
|
4
4
|
[![Downloads Total](https://img.shields.io/gem/dt/config)](https://rubygems.org/gems/config)
|
5
|
-
[![Build](https://img.shields.io/github/workflow/status/rubyconfig/config/tests)](https://rubygems.org/gems/config)
|
6
5
|
[![Tests](https://github.com/rubyconfig/config/workflows/tests/badge.svg)](https://github.com/rubyconfig/config/actions?query=branch%3Amaster)
|
7
6
|
[![Financial Contributors on Open Collective](https://opencollective.com/rubyconfig/all/badge.svg?label=backers)](https://opencollective.com/rubyconfig)
|
8
7
|
|
data/config.gemspec
CHANGED
@@ -8,9 +8,9 @@ Gem::Specification.new do |s|
|
|
8
8
|
s.date = Time.now.strftime '%F'
|
9
9
|
s.authors = ['Piotr Kuczynski', 'Fred Wu', 'Jacques Crocker']
|
10
10
|
s.email = %w[piotr.kuczynski@gmail.com ifredwu@gmail.com railsjedi@gmail.com]
|
11
|
-
s.summary = 'Effortless multi-environment settings in Rails, Sinatra,
|
11
|
+
s.summary = 'Effortless multi-environment settings in Rails, Sinatra, Padrino and others'
|
12
12
|
s.description = 'Easiest way to manage multi-environment settings in any ruby project or framework: ' +
|
13
|
-
'Rails, Sinatra,
|
13
|
+
'Rails, Sinatra, Padrino and others'
|
14
14
|
s.homepage = 'https://github.com/rubyconfig/config'
|
15
15
|
s.license = 'MIT'
|
16
16
|
s.extra_rdoc_files = %w[README.md CHANGELOG.md CONTRIBUTING.md LICENSE.md]
|
@@ -32,7 +32,7 @@ Donate: \e[34mhttps://opencollective.com/rubyconfig/donate\e[0m\n"
|
|
32
32
|
s.add_development_dependency 'rake', '~> 12.0', '>= 12.0.0'
|
33
33
|
|
34
34
|
# Testing
|
35
|
-
s.add_development_dependency 'appraisal', '~> 2.
|
35
|
+
s.add_development_dependency 'appraisal', '~> 2.5', '>= 2.5.0'
|
36
36
|
s.add_development_dependency 'rspec', '~> 3.9', '>= 3.9.0'
|
37
37
|
|
38
38
|
# Default RSpec run will test against latest Rails app
|
data/lib/config/options.rb
CHANGED
@@ -112,7 +112,7 @@ module Config
|
|
112
112
|
end
|
113
113
|
|
114
114
|
# Some keywords that don't play nicely with OpenStruct
|
115
|
-
SETTINGS_RESERVED_NAMES = %w[select collect test count zip min max exit!].freeze
|
115
|
+
SETTINGS_RESERVED_NAMES = %w[select collect test count zip min max exit! table].freeze
|
116
116
|
|
117
117
|
# An alternative mechanism for property access.
|
118
118
|
# This let's you do foo['bar'] along with foo.bar.
|
@@ -132,11 +132,11 @@ module Config
|
|
132
132
|
end
|
133
133
|
|
134
134
|
def key?(key)
|
135
|
-
table.key?(key)
|
135
|
+
@table.key?(key)
|
136
136
|
end
|
137
137
|
|
138
138
|
def has_key?(key)
|
139
|
-
table.has_key?(key)
|
139
|
+
@table.has_key?(key)
|
140
140
|
end
|
141
141
|
|
142
142
|
def method_missing(method_name, *args)
|
@@ -22,10 +22,10 @@ module Config
|
|
22
22
|
|
23
23
|
result || {}
|
24
24
|
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
25
|
+
rescue Psych::SyntaxError => e
|
26
|
+
raise "YAML syntax error occurred while parsing #{@path}. " \
|
27
|
+
"Please note that YAML must be consistently indented using spaces. Tabs are not allowed. " \
|
28
|
+
"Error: #{e.message}"
|
29
29
|
end
|
30
30
|
end
|
31
31
|
end
|
data/lib/config/version.rb
CHANGED
data/lib/config.rb
CHANGED
@@ -6,7 +6,7 @@ require 'config/sources/yaml_source'
|
|
6
6
|
require 'config/sources/hash_source'
|
7
7
|
require 'config/sources/env_source'
|
8
8
|
require 'config/validation/schema'
|
9
|
-
require 'deep_merge'
|
9
|
+
require 'deep_merge/core'
|
10
10
|
|
11
11
|
module Config
|
12
12
|
extend Config::Validation::Schema
|
@@ -79,7 +79,7 @@ module Config
|
|
79
79
|
end
|
80
80
|
|
81
81
|
# Rails integration
|
82
|
-
require('config/integrations/rails/railtie') if defined?(::Rails)
|
82
|
+
require('config/integrations/rails/railtie') if defined?(::Rails::Railtie)
|
83
83
|
|
84
84
|
# Sinatra integration
|
85
85
|
require('config/integrations/sinatra') if defined?(::Sinatra)
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: config
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 5.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Piotr Kuczynski
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date:
|
13
|
+
date: 2023-10-18 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: deep_merge
|
@@ -78,20 +78,20 @@ dependencies:
|
|
78
78
|
requirements:
|
79
79
|
- - "~>"
|
80
80
|
- !ruby/object:Gem::Version
|
81
|
-
version: '2.
|
81
|
+
version: '2.5'
|
82
82
|
- - ">="
|
83
83
|
- !ruby/object:Gem::Version
|
84
|
-
version: 2.
|
84
|
+
version: 2.5.0
|
85
85
|
type: :development
|
86
86
|
prerelease: false
|
87
87
|
version_requirements: !ruby/object:Gem::Requirement
|
88
88
|
requirements:
|
89
89
|
- - "~>"
|
90
90
|
- !ruby/object:Gem::Version
|
91
|
-
version: '2.
|
91
|
+
version: '2.5'
|
92
92
|
- - ">="
|
93
93
|
- !ruby/object:Gem::Version
|
94
|
-
version: 2.
|
94
|
+
version: 2.5.0
|
95
95
|
- !ruby/object:Gem::Dependency
|
96
96
|
name: rspec
|
97
97
|
requirement: !ruby/object:Gem::Requirement
|
@@ -118,42 +118,56 @@ dependencies:
|
|
118
118
|
requirements:
|
119
119
|
- - ">="
|
120
120
|
- !ruby/object:Gem::Version
|
121
|
-
version: 1.
|
121
|
+
version: 1.16.0
|
122
122
|
type: :development
|
123
123
|
prerelease: false
|
124
124
|
version_requirements: !ruby/object:Gem::Requirement
|
125
125
|
requirements:
|
126
126
|
- - ">="
|
127
127
|
- !ruby/object:Gem::Version
|
128
|
-
version: 1.
|
128
|
+
version: 1.16.0
|
129
129
|
- !ruby/object:Gem::Dependency
|
130
130
|
name: rails
|
131
131
|
requirement: !ruby/object:Gem::Requirement
|
132
132
|
requirements:
|
133
133
|
- - '='
|
134
134
|
- !ruby/object:Gem::Version
|
135
|
-
version:
|
135
|
+
version: 7.1.0
|
136
136
|
type: :development
|
137
137
|
prerelease: false
|
138
138
|
version_requirements: !ruby/object:Gem::Requirement
|
139
139
|
requirements:
|
140
140
|
- - '='
|
141
141
|
- !ruby/object:Gem::Version
|
142
|
-
version:
|
142
|
+
version: 7.1.0
|
143
143
|
- !ruby/object:Gem::Dependency
|
144
144
|
name: rspec-rails
|
145
145
|
requirement: !ruby/object:Gem::Requirement
|
146
146
|
requirements:
|
147
147
|
- - "~>"
|
148
148
|
- !ruby/object:Gem::Version
|
149
|
-
version:
|
149
|
+
version: 6.0.3
|
150
150
|
type: :development
|
151
151
|
prerelease: false
|
152
152
|
version_requirements: !ruby/object:Gem::Requirement
|
153
153
|
requirements:
|
154
154
|
- - "~>"
|
155
155
|
- !ruby/object:Gem::Version
|
156
|
-
version:
|
156
|
+
version: 6.0.3
|
157
|
+
- !ruby/object:Gem::Dependency
|
158
|
+
name: sprockets-rails
|
159
|
+
requirement: !ruby/object:Gem::Requirement
|
160
|
+
requirements:
|
161
|
+
- - "~>"
|
162
|
+
- !ruby/object:Gem::Version
|
163
|
+
version: 3.4.2
|
164
|
+
type: :development
|
165
|
+
prerelease: false
|
166
|
+
version_requirements: !ruby/object:Gem::Requirement
|
167
|
+
requirements:
|
168
|
+
- - "~>"
|
169
|
+
- !ruby/object:Gem::Version
|
170
|
+
version: 3.4.2
|
157
171
|
- !ruby/object:Gem::Dependency
|
158
172
|
name: psych
|
159
173
|
requirement: !ruby/object:Gem::Requirement
|
@@ -203,7 +217,7 @@ dependencies:
|
|
203
217
|
- !ruby/object:Gem::Version
|
204
218
|
version: 0.85.0
|
205
219
|
description: 'Easiest way to manage multi-environment settings in any ruby project
|
206
|
-
or framework: Rails, Sinatra,
|
220
|
+
or framework: Rails, Sinatra, Padrino and others'
|
207
221
|
email:
|
208
222
|
- piotr.kuczynski@gmail.com
|
209
223
|
- ifredwu@gmail.com
|
@@ -265,8 +279,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
265
279
|
- !ruby/object:Gem::Version
|
266
280
|
version: '0'
|
267
281
|
requirements: []
|
268
|
-
rubygems_version: 3.
|
282
|
+
rubygems_version: 3.4.10
|
269
283
|
signing_key:
|
270
284
|
specification_version: 4
|
271
|
-
summary: Effortless multi-environment settings in Rails, Sinatra,
|
285
|
+
summary: Effortless multi-environment settings in Rails, Sinatra, Padrino and others
|
272
286
|
test_files: []
|