a9n 1.6.0 → 1.8.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/.github/workflows/ruby.yml +1 -1
- data/.standard.yml +1 -0
- data/Gemfile +6 -7
- data/Gemfile.lock +58 -24
- data/Rakefile +6 -7
- data/a9n.gemspec +17 -16
- data/lib/a9n/capistrano/ver2x.rb +2 -2
- data/lib/a9n/capistrano.rb +2 -2
- data/lib/a9n/ext/hash.rb +1 -2
- data/lib/a9n/ext/string_inquirer.rb +2 -2
- data/lib/a9n/loader.rb +6 -6
- data/lib/a9n/scope.rb +1 -1
- data/lib/a9n/struct.rb +6 -2
- data/lib/a9n/version.rb +1 -1
- data/lib/a9n/yaml_loader.rb +1 -1
- data/lib/a9n.rb +34 -31
- metadata +18 -3
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 13e9942b8ef776fa4d56f0c2d1bf6c2f853564e4d72675e9b12c5e03a01c0eaa
|
|
4
|
+
data.tar.gz: 4c011c593cd93809708a918cfb1734f59fa07e178011f509c81b764e7e2a674b
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 20ee0656ae050ad8569172de44baa3bfc3a0f0f7b81ce9067980c18137c0bb5edb5fcadf532e9245009d44d1805631ee3923af5c6ec2a034e6e1466591c2d3e6
|
|
7
|
+
data.tar.gz: a18db3a3439ad0f8a6b8f4afb88e0e4e3779058a59c5abe6c412822dc8843967728953971a8741ff200e8a6170685a0a41f76baa8a048923b19eaf1de8dcfe74
|
data/.github/workflows/ruby.yml
CHANGED
data/.standard.yml
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
ruby_version: 3.4
|
data/Gemfile
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
source
|
|
1
|
+
source "https://rubygems.org"
|
|
2
2
|
|
|
3
3
|
gemspec
|
|
4
4
|
|
|
5
|
-
gem
|
|
6
|
-
gem
|
|
7
|
-
gem
|
|
8
|
-
gem
|
|
9
|
-
gem
|
|
10
|
-
gem 'rubocop-rspec'
|
|
5
|
+
gem "pry"
|
|
6
|
+
gem "rake"
|
|
7
|
+
gem "rspec"
|
|
8
|
+
gem "standard", ">= 1.35.1"
|
|
9
|
+
gem "standard-rspec"
|
data/Gemfile.lock
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
PATH
|
|
2
2
|
remote: .
|
|
3
3
|
specs:
|
|
4
|
-
a9n (1.
|
|
4
|
+
a9n (1.8.0)
|
|
5
|
+
logger
|
|
5
6
|
ostruct
|
|
6
7
|
|
|
7
8
|
GEM
|
|
@@ -10,37 +11,42 @@ GEM
|
|
|
10
11
|
ast (2.4.3)
|
|
11
12
|
coderay (1.1.3)
|
|
12
13
|
diff-lcs (1.6.2)
|
|
13
|
-
|
|
14
|
+
io-console (0.8.2)
|
|
15
|
+
json (2.19.2)
|
|
14
16
|
language_server-protocol (3.17.0.5)
|
|
15
17
|
lint_roller (1.1.0)
|
|
18
|
+
logger (1.7.0)
|
|
16
19
|
method_source (1.1.0)
|
|
17
20
|
ostruct (0.6.3)
|
|
18
21
|
parallel (1.27.0)
|
|
19
|
-
parser (3.3.
|
|
22
|
+
parser (3.3.10.2)
|
|
20
23
|
ast (~> 2.4.1)
|
|
21
24
|
racc
|
|
22
|
-
prism (1.
|
|
23
|
-
pry (0.
|
|
25
|
+
prism (1.9.0)
|
|
26
|
+
pry (0.16.0)
|
|
24
27
|
coderay (~> 1.1)
|
|
25
28
|
method_source (~> 1.0)
|
|
29
|
+
reline (>= 0.6.0)
|
|
26
30
|
racc (1.8.1)
|
|
27
31
|
rainbow (3.1.1)
|
|
28
|
-
rake (13.3.
|
|
29
|
-
regexp_parser (2.11.
|
|
30
|
-
|
|
32
|
+
rake (13.3.1)
|
|
33
|
+
regexp_parser (2.11.3)
|
|
34
|
+
reline (0.6.3)
|
|
35
|
+
io-console (~> 0.5)
|
|
36
|
+
rspec (3.13.2)
|
|
31
37
|
rspec-core (~> 3.13.0)
|
|
32
38
|
rspec-expectations (~> 3.13.0)
|
|
33
39
|
rspec-mocks (~> 3.13.0)
|
|
34
|
-
rspec-core (3.13.
|
|
40
|
+
rspec-core (3.13.6)
|
|
35
41
|
rspec-support (~> 3.13.0)
|
|
36
42
|
rspec-expectations (3.13.5)
|
|
37
43
|
diff-lcs (>= 1.2.0, < 2.0)
|
|
38
44
|
rspec-support (~> 3.13.0)
|
|
39
|
-
rspec-mocks (3.13.
|
|
45
|
+
rspec-mocks (3.13.8)
|
|
40
46
|
diff-lcs (>= 1.2.0, < 2.0)
|
|
41
47
|
rspec-support (~> 3.13.0)
|
|
42
|
-
rspec-support (3.13.
|
|
43
|
-
rubocop (1.
|
|
48
|
+
rspec-support (3.13.7)
|
|
49
|
+
rubocop (1.84.2)
|
|
44
50
|
json (~> 2.3)
|
|
45
51
|
language_server-protocol (~> 3.17.0.2)
|
|
46
52
|
lint_roller (~> 1.1.0)
|
|
@@ -48,22 +54,51 @@ GEM
|
|
|
48
54
|
parser (>= 3.3.0.2)
|
|
49
55
|
rainbow (>= 2.2.2, < 4.0)
|
|
50
56
|
regexp_parser (>= 2.9.3, < 3.0)
|
|
51
|
-
rubocop-ast (>= 1.
|
|
57
|
+
rubocop-ast (>= 1.49.0, < 2.0)
|
|
52
58
|
ruby-progressbar (~> 1.7)
|
|
53
59
|
unicode-display_width (>= 2.4.0, < 4.0)
|
|
54
|
-
rubocop-ast (1.
|
|
60
|
+
rubocop-ast (1.49.1)
|
|
55
61
|
parser (>= 3.3.7.2)
|
|
56
|
-
prism (~> 1.
|
|
57
|
-
rubocop-
|
|
62
|
+
prism (~> 1.7)
|
|
63
|
+
rubocop-capybara (2.22.1)
|
|
58
64
|
lint_roller (~> 1.1)
|
|
59
|
-
rubocop (>= 1.72.1)
|
|
60
|
-
rubocop-
|
|
65
|
+
rubocop (~> 1.72, >= 1.72.1)
|
|
66
|
+
rubocop-factory_bot (2.28.0)
|
|
61
67
|
lint_roller (~> 1.1)
|
|
62
68
|
rubocop (~> 1.72, >= 1.72.1)
|
|
69
|
+
rubocop-performance (1.26.1)
|
|
70
|
+
lint_roller (~> 1.1)
|
|
71
|
+
rubocop (>= 1.75.0, < 2.0)
|
|
72
|
+
rubocop-ast (>= 1.47.1, < 2.0)
|
|
73
|
+
rubocop-rspec (3.9.0)
|
|
74
|
+
lint_roller (~> 1.1)
|
|
75
|
+
rubocop (~> 1.81)
|
|
76
|
+
rubocop-rspec_rails (2.32.0)
|
|
77
|
+
lint_roller (~> 1.1)
|
|
78
|
+
rubocop (~> 1.72, >= 1.72.1)
|
|
79
|
+
rubocop-rspec (~> 3.5)
|
|
63
80
|
ruby-progressbar (1.13.0)
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
81
|
+
standard (1.54.0)
|
|
82
|
+
language_server-protocol (~> 3.17.0.2)
|
|
83
|
+
lint_roller (~> 1.0)
|
|
84
|
+
rubocop (~> 1.84.0)
|
|
85
|
+
standard-custom (~> 1.0.0)
|
|
86
|
+
standard-performance (~> 1.8)
|
|
87
|
+
standard-custom (1.0.2)
|
|
88
|
+
lint_roller (~> 1.0)
|
|
89
|
+
rubocop (~> 1.50)
|
|
90
|
+
standard-performance (1.9.0)
|
|
91
|
+
lint_roller (~> 1.1)
|
|
92
|
+
rubocop-performance (~> 1.26.0)
|
|
93
|
+
standard-rspec (0.4.0)
|
|
94
|
+
lint_roller (>= 1.0)
|
|
95
|
+
rubocop-capybara (~> 2.22)
|
|
96
|
+
rubocop-factory_bot (~> 2.27)
|
|
97
|
+
rubocop-rspec (~> 3.9)
|
|
98
|
+
rubocop-rspec_rails (~> 2.31)
|
|
99
|
+
unicode-display_width (3.2.0)
|
|
100
|
+
unicode-emoji (~> 4.1)
|
|
101
|
+
unicode-emoji (4.2.0)
|
|
67
102
|
|
|
68
103
|
PLATFORMS
|
|
69
104
|
ruby
|
|
@@ -76,9 +111,8 @@ DEPENDENCIES
|
|
|
76
111
|
pry
|
|
77
112
|
rake
|
|
78
113
|
rspec
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
rubocop-rspec
|
|
114
|
+
standard (>= 1.35.1)
|
|
115
|
+
standard-rspec
|
|
82
116
|
|
|
83
117
|
BUNDLED WITH
|
|
84
118
|
2.7.1
|
data/Rakefile
CHANGED
|
@@ -1,11 +1,10 @@
|
|
|
1
|
-
require
|
|
2
|
-
require
|
|
3
|
-
require
|
|
1
|
+
require "bundler/gem_tasks"
|
|
2
|
+
require "rspec/core/rake_task"
|
|
3
|
+
require "standard/rake"
|
|
4
4
|
|
|
5
5
|
RSpec::Core::RakeTask.new(:spec)
|
|
6
|
-
RuboCop::RakeTask.new
|
|
7
6
|
|
|
8
|
-
desc
|
|
9
|
-
task ci: %i[spec
|
|
7
|
+
desc "Default task to run on ci"
|
|
8
|
+
task ci: %i[spec standard]
|
|
10
9
|
|
|
11
|
-
task default: %i[spec
|
|
10
|
+
task default: %i[spec standard:fix]
|
data/a9n.gemspec
CHANGED
|
@@ -1,26 +1,27 @@
|
|
|
1
|
-
require File.expand_path(
|
|
1
|
+
require File.expand_path("lib/a9n/version", __dir__)
|
|
2
2
|
|
|
3
3
|
Gem::Specification.new do |spec|
|
|
4
|
-
spec.name
|
|
5
|
-
spec.version
|
|
6
|
-
spec.authors
|
|
7
|
-
spec.email
|
|
4
|
+
spec.name = "a9n"
|
|
5
|
+
spec.version = A9n::VERSION
|
|
6
|
+
spec.authors = ["Krzysztof Knapik"]
|
|
7
|
+
spec.email = ["knapo@knapo.net"]
|
|
8
8
|
|
|
9
|
-
spec.summary
|
|
10
|
-
spec.homepage =
|
|
11
|
-
spec.license
|
|
9
|
+
spec.summary = "a9n - ruby/rails apps configuration manager"
|
|
10
|
+
spec.homepage = "https://github.com/knapo/a9n"
|
|
11
|
+
spec.license = "MIT"
|
|
12
12
|
|
|
13
|
-
spec.metadata[
|
|
14
|
-
spec.metadata[
|
|
15
|
-
spec.metadata[
|
|
13
|
+
spec.metadata["homepage_uri"] = "https://github.com/knapo/a9n"
|
|
14
|
+
spec.metadata["source_code_uri"] = "https://github.com/knapo/a9n"
|
|
15
|
+
spec.metadata["rubygems_mfa_required"] = "true"
|
|
16
16
|
|
|
17
17
|
spec.files = Dir.chdir(__dir__) do
|
|
18
18
|
`git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(bin/|spec/|test_app/|\.rub)}) }
|
|
19
19
|
end
|
|
20
|
-
spec.bindir
|
|
21
|
-
spec.executables
|
|
22
|
-
spec.require_paths = [
|
|
20
|
+
spec.bindir = "exe"
|
|
21
|
+
spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
|
|
22
|
+
spec.require_paths = ["lib"]
|
|
23
23
|
|
|
24
|
-
spec.required_ruby_version =
|
|
25
|
-
spec.add_dependency
|
|
24
|
+
spec.required_ruby_version = ">= 3.4"
|
|
25
|
+
spec.add_dependency "logger"
|
|
26
|
+
spec.add_dependency "ostruct"
|
|
26
27
|
end
|
data/lib/a9n/capistrano/ver2x.rb
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
Capistrano::Configuration.instance.load do
|
|
2
|
-
after
|
|
2
|
+
after "deploy:update_code", "a9n:copy_stage_config"
|
|
3
3
|
|
|
4
4
|
namespace :a9n do
|
|
5
|
-
desc
|
|
5
|
+
desc "Copy stage configuration to base file."
|
|
6
6
|
task :copy_stage_config, roles: :app do
|
|
7
7
|
run "cp #{fetch(:release_path)}/config/configuration.yml.#{fetch(:stage)} #{fetch(:release_path)}/config/configuration.yml"
|
|
8
8
|
end
|
data/lib/a9n/capistrano.rb
CHANGED
data/lib/a9n/ext/hash.rb
CHANGED
|
@@ -2,10 +2,9 @@ module A9n
|
|
|
2
2
|
class Hash
|
|
3
3
|
class << self
|
|
4
4
|
def deep_prepare(hash, scope)
|
|
5
|
-
hash.
|
|
5
|
+
hash.each_with_object({}) do |(key, value), result|
|
|
6
6
|
key_name = key.respond_to?(:to_sym) ? key.to_sym : key
|
|
7
7
|
result[key_name] = get_value(key, value, scope)
|
|
8
|
-
result
|
|
9
8
|
end
|
|
10
9
|
end
|
|
11
10
|
|
|
@@ -4,11 +4,11 @@ module A9n
|
|
|
4
4
|
private
|
|
5
5
|
|
|
6
6
|
def respond_to_missing?(method_name, include_private = false)
|
|
7
|
-
(method_name[-1] ==
|
|
7
|
+
(method_name[-1] == "?") || super
|
|
8
8
|
end
|
|
9
9
|
|
|
10
10
|
def method_missing(method_name, *arguments)
|
|
11
|
-
if method_name[-1] ==
|
|
11
|
+
if method_name[-1] == "?"
|
|
12
12
|
self == method_name[0..-2]
|
|
13
13
|
else
|
|
14
14
|
super
|
data/lib/a9n/loader.rb
CHANGED
|
@@ -2,8 +2,8 @@ module A9n
|
|
|
2
2
|
class Loader
|
|
3
3
|
attr_reader :scope, :env, :local_file, :example_file, :struct
|
|
4
4
|
|
|
5
|
-
COMMON_NAMESPACE =
|
|
6
|
-
KNOWN_NAMESPACES = [COMMON_NAMESPACE,
|
|
5
|
+
COMMON_NAMESPACE = "defaults".freeze
|
|
6
|
+
KNOWN_NAMESPACES = [COMMON_NAMESPACE, "development", "test", "staging", "production"].freeze
|
|
7
7
|
|
|
8
8
|
def initialize(file_path, scope, env)
|
|
9
9
|
@scope = scope
|
|
@@ -17,8 +17,8 @@ module A9n
|
|
|
17
17
|
end
|
|
18
18
|
|
|
19
19
|
def load
|
|
20
|
-
local_config
|
|
21
|
-
example_config
|
|
20
|
+
local_config = self.class.load_yml(local_file, scope, env)
|
|
21
|
+
example_config = self.class.load_yml(example_file, scope, env)
|
|
22
22
|
|
|
23
23
|
ensure_data_presence!(local_config, example_config)
|
|
24
24
|
ensure_keys_presence!(local_config, example_config)
|
|
@@ -36,7 +36,7 @@ module A9n
|
|
|
36
36
|
prepare_hash(yml, scope).freeze
|
|
37
37
|
else
|
|
38
38
|
common_namespace = prepare_hash(yml[COMMON_NAMESPACE], scope)
|
|
39
|
-
env_namespace
|
|
39
|
+
env_namespace = prepare_hash(yml[env], scope)
|
|
40
40
|
|
|
41
41
|
A9n::Hash.merge(common_namespace, env_namespace).freeze
|
|
42
42
|
end
|
|
@@ -70,7 +70,7 @@ module A9n
|
|
|
70
70
|
|
|
71
71
|
return if missing_keys.empty?
|
|
72
72
|
|
|
73
|
-
raise A9n::MissingConfigurationVariablesError, "Following variables are missing in #{local_file} file: #{missing_keys.join(
|
|
73
|
+
raise A9n::MissingConfigurationVariablesError, "Following variables are missing in #{local_file} file: #{missing_keys.join(",")}"
|
|
74
74
|
end
|
|
75
75
|
end
|
|
76
76
|
end
|
data/lib/a9n/scope.rb
CHANGED
data/lib/a9n/struct.rb
CHANGED
|
@@ -10,8 +10,8 @@ module A9n
|
|
|
10
10
|
@data = data
|
|
11
11
|
end
|
|
12
12
|
|
|
13
|
-
|
|
14
|
-
|
|
13
|
+
alias_method :to_hash, :data
|
|
14
|
+
alias_method :to_h, :data
|
|
15
15
|
|
|
16
16
|
def merge(another_data)
|
|
17
17
|
data.merge!(another_data)
|
|
@@ -29,6 +29,10 @@ module A9n
|
|
|
29
29
|
find(key)
|
|
30
30
|
end
|
|
31
31
|
|
|
32
|
+
def respond_to_missing?(key, include_private = false)
|
|
33
|
+
data.key?(key.to_sym) || super
|
|
34
|
+
end
|
|
35
|
+
|
|
32
36
|
def set(key, value)
|
|
33
37
|
data[key.to_sym] = value
|
|
34
38
|
end
|
data/lib/a9n/version.rb
CHANGED
data/lib/a9n/yaml_loader.rb
CHANGED
data/lib/a9n.rb
CHANGED
|
@@ -1,24 +1,24 @@
|
|
|
1
|
-
require
|
|
2
|
-
require
|
|
3
|
-
require
|
|
4
|
-
require
|
|
5
|
-
require
|
|
6
|
-
require
|
|
7
|
-
require
|
|
8
|
-
require
|
|
9
|
-
require
|
|
10
|
-
require
|
|
11
|
-
require
|
|
12
|
-
require
|
|
13
|
-
require
|
|
14
|
-
require
|
|
1
|
+
require "forwardable"
|
|
2
|
+
require "pathname"
|
|
3
|
+
require "ostruct"
|
|
4
|
+
require "yaml"
|
|
5
|
+
require "erb"
|
|
6
|
+
require "logger"
|
|
7
|
+
require "a9n/version"
|
|
8
|
+
require "a9n/exceptions"
|
|
9
|
+
require "a9n/struct"
|
|
10
|
+
require "a9n/scope"
|
|
11
|
+
require "a9n/ext/string_inquirer"
|
|
12
|
+
require "a9n/ext/hash"
|
|
13
|
+
require "a9n/yaml_loader"
|
|
14
|
+
require "a9n/loader"
|
|
15
15
|
|
|
16
16
|
module A9n
|
|
17
17
|
extend SingleForwardable
|
|
18
18
|
|
|
19
|
-
EXTENSION_LIST =
|
|
20
|
-
STRICT_MODE =
|
|
21
|
-
DEFAULT_LOG_LEVEL =
|
|
19
|
+
EXTENSION_LIST = "{yml,yml.erb,yml.example,yml.erb.example}".freeze
|
|
20
|
+
STRICT_MODE = "strict".freeze
|
|
21
|
+
DEFAULT_LOG_LEVEL = "info".freeze
|
|
22
22
|
|
|
23
23
|
class << self
|
|
24
24
|
attr_writer :logger
|
|
@@ -26,9 +26,9 @@ module A9n
|
|
|
26
26
|
def env
|
|
27
27
|
@env ||= ::A9n::StringInquirer.new(
|
|
28
28
|
app_env ||
|
|
29
|
-
env_var(
|
|
30
|
-
env_var(
|
|
31
|
-
env_var(
|
|
29
|
+
env_var("APP_ENV") ||
|
|
30
|
+
env_var("RACK_ENV") ||
|
|
31
|
+
env_var("RAILS_ENV") ||
|
|
32
32
|
raise(UnknownEnvError)
|
|
33
33
|
)
|
|
34
34
|
end
|
|
@@ -45,9 +45,7 @@ module A9n
|
|
|
45
45
|
@app ||= rails_app
|
|
46
46
|
end
|
|
47
47
|
|
|
48
|
-
|
|
49
|
-
@app = app_instance
|
|
50
|
-
end
|
|
48
|
+
attr_writer :app
|
|
51
49
|
|
|
52
50
|
def root
|
|
53
51
|
@root ||= app_root || root_from_bundle_env || raise(RootNotSetError)
|
|
@@ -58,9 +56,9 @@ module A9n
|
|
|
58
56
|
end
|
|
59
57
|
|
|
60
58
|
def root_from_bundle_env
|
|
61
|
-
return nil unless ENV[
|
|
59
|
+
return nil unless ENV["BUNDLE_GEMFILE"]
|
|
62
60
|
|
|
63
|
-
dir = File.dirname(ENV.fetch(
|
|
61
|
+
dir = File.dirname(ENV.fetch("BUNDLE_GEMFILE", nil))
|
|
64
62
|
|
|
65
63
|
return nil unless File.directory?(dir)
|
|
66
64
|
|
|
@@ -72,7 +70,7 @@ module A9n
|
|
|
72
70
|
end
|
|
73
71
|
|
|
74
72
|
def groups
|
|
75
|
-
[
|
|
73
|
+
["default", env].compact.freeze
|
|
76
74
|
end
|
|
77
75
|
|
|
78
76
|
def rails_app
|
|
@@ -90,9 +88,9 @@ module A9n
|
|
|
90
88
|
end
|
|
91
89
|
|
|
92
90
|
def default_files
|
|
93
|
-
files
|
|
91
|
+
files = Dir[root.join("config/{#{A9n::Scope::ROOT_NAMES.join(",")}}.#{EXTENSION_LIST}").to_s]
|
|
94
92
|
files += Dir[root.join("config/a9n/*.#{EXTENSION_LIST}")]
|
|
95
|
-
files.map { |f| f.sub(/.example$/,
|
|
93
|
+
files.map { |f| f.sub(/.example$/, "") }.uniq.sort
|
|
96
94
|
end
|
|
97
95
|
|
|
98
96
|
def load(*files)
|
|
@@ -106,7 +104,7 @@ module A9n
|
|
|
106
104
|
end
|
|
107
105
|
|
|
108
106
|
def mode
|
|
109
|
-
ENV[
|
|
107
|
+
ENV["A9N_MODE"] || STRICT_MODE
|
|
110
108
|
end
|
|
111
109
|
|
|
112
110
|
def strict?
|
|
@@ -122,6 +120,11 @@ module A9n
|
|
|
122
120
|
storage.send(name, *)
|
|
123
121
|
end
|
|
124
122
|
|
|
123
|
+
def respond_to_missing?(name, include_private = false)
|
|
124
|
+
load if storage.empty?
|
|
125
|
+
storage.respond_to?(name, include_private) || super
|
|
126
|
+
end
|
|
127
|
+
|
|
125
128
|
private
|
|
126
129
|
|
|
127
130
|
def load_file(file)
|
|
@@ -144,13 +147,13 @@ module A9n
|
|
|
144
147
|
end
|
|
145
148
|
|
|
146
149
|
def absolute_paths_for(files)
|
|
147
|
-
files.map { |file| Pathname.new(file).absolute? ? file : root.join(
|
|
150
|
+
files.map { |file| Pathname.new(file).absolute? ? file : root.join("config", file).to_s }
|
|
148
151
|
end
|
|
149
152
|
|
|
150
153
|
def require_local_extension
|
|
151
154
|
return if root.nil?
|
|
152
155
|
|
|
153
|
-
local_extension_file = File.join(root,
|
|
156
|
+
local_extension_file = File.join(root, "config/a9n.rb")
|
|
154
157
|
|
|
155
158
|
return unless File.exist?(local_extension_file)
|
|
156
159
|
|
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: a9n
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 1.
|
|
4
|
+
version: 1.8.0
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Krzysztof Knapik
|
|
@@ -9,6 +9,20 @@ bindir: exe
|
|
|
9
9
|
cert_chain: []
|
|
10
10
|
date: 1980-01-02 00:00:00.000000000 Z
|
|
11
11
|
dependencies:
|
|
12
|
+
- !ruby/object:Gem::Dependency
|
|
13
|
+
name: logger
|
|
14
|
+
requirement: !ruby/object:Gem::Requirement
|
|
15
|
+
requirements:
|
|
16
|
+
- - ">="
|
|
17
|
+
- !ruby/object:Gem::Version
|
|
18
|
+
version: '0'
|
|
19
|
+
type: :runtime
|
|
20
|
+
prerelease: false
|
|
21
|
+
version_requirements: !ruby/object:Gem::Requirement
|
|
22
|
+
requirements:
|
|
23
|
+
- - ">="
|
|
24
|
+
- !ruby/object:Gem::Version
|
|
25
|
+
version: '0'
|
|
12
26
|
- !ruby/object:Gem::Dependency
|
|
13
27
|
name: ostruct
|
|
14
28
|
requirement: !ruby/object:Gem::Requirement
|
|
@@ -32,6 +46,7 @@ files:
|
|
|
32
46
|
- ".github/workflows/ruby.yml"
|
|
33
47
|
- ".gitignore"
|
|
34
48
|
- ".rspec"
|
|
49
|
+
- ".standard.yml"
|
|
35
50
|
- Gemfile
|
|
36
51
|
- Gemfile.lock
|
|
37
52
|
- LICENSE
|
|
@@ -64,14 +79,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
|
64
79
|
requirements:
|
|
65
80
|
- - ">="
|
|
66
81
|
- !ruby/object:Gem::Version
|
|
67
|
-
version: '3.
|
|
82
|
+
version: '3.4'
|
|
68
83
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
|
69
84
|
requirements:
|
|
70
85
|
- - ">="
|
|
71
86
|
- !ruby/object:Gem::Version
|
|
72
87
|
version: '0'
|
|
73
88
|
requirements: []
|
|
74
|
-
rubygems_version:
|
|
89
|
+
rubygems_version: 4.0.8
|
|
75
90
|
specification_version: 4
|
|
76
91
|
summary: a9n - ruby/rails apps configuration manager
|
|
77
92
|
test_files: []
|