rdm 0.0.8 → 0.1.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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: a4b6d8edc3b721e97e1198de21d5fca64bf82a77
4
- data.tar.gz: 0867d57abb893daa476939a0fa6a1adbb4badb4d
3
+ metadata.gz: 35b42b35fcc5367b1c18ae0f1b6d8033f009df34
4
+ data.tar.gz: b6fca01a756586a5eb6d05226e29acff193ce7b8
5
5
  SHA512:
6
- metadata.gz: 28dde8933c61a5eee9892afaa1b159371b500e7e6787dbeb2a8a87ec9527cc43ef2d9b286b93a80f449e6b247cb1d7e77e603fb233ca70afe6ea4c30585b94f5
7
- data.tar.gz: de3929b057b877a871dd3c2d4608f6118f944a167654286e2ace45fbd506df09c95ea44b2be29a866dda9f394279e2120477027b0a1dc7b19201bab8ae5777ce
6
+ metadata.gz: 54310892fb7010fd6bb359a9003dd03b646e41b9df44d4f9077d44d3d5f5e6ff26e66cafa264dfdd3aa7fda65046c22479b3c7792c3c77454f24b79b952792a4
7
+ data.tar.gz: 1bafac3c332def046b7b40d0307c5c2ad2af0574b9a4d53080e3f94ce9c2d47a8b3e61263e66fe96a7f8433c4b60a42f61ea98ee2d0695e4e647894e4f536aa9
@@ -45,10 +45,11 @@ class Rdm::PackageImporter
45
45
  # only after importing dependencies - require package itself
46
46
  begin
47
47
  require package_name
48
- rescue LoadError
49
- if Rdm.settings.raises_missing_package_file_exception
48
+ rescue LoadError => e
49
+ unless Rdm.settings.silence_missing_package_file_exception
50
50
  package_require_path = "#{package_name}/#{package_subdir_name}/#{package_name}.rb"
51
- raise "Can't require package #{package_name}, please create file #{package_require_path}"
51
+ puts "WARNING: Can't require package #{package_name}, please make sure that file #{package_require_path} exists and it's valid."
52
+ raise e
52
53
  end
53
54
  end
54
55
 
data/lib/rdm/settings.rb CHANGED
@@ -1,6 +1,6 @@
1
1
  class Rdm::Settings
2
2
  SETTING_KEYS = [
3
- :role, :raises_missing_package_file_exception, :package_subdir_name,
3
+ :role, :silence_missing_package_file_exception, :package_subdir_name,
4
4
  :configs_dir, :config_path, :role_config_path
5
5
  ]
6
6
 
@@ -8,7 +8,7 @@ class Rdm::Settings
8
8
 
9
9
  # Default settings
10
10
  def initialize
11
- raises_missing_package_file_exception(true)
11
+ silence_missing_package_file_exception(false)
12
12
  package_subdir_name("package")
13
13
  configs_dir('configs')
14
14
  end
data/lib/rdm/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module Rdm
2
- VERSION = "0.0.8"
2
+ VERSION = "0.1.0"
3
3
  end
@@ -76,7 +76,6 @@ describe Rdm::ConfigManager do
76
76
  end
77
77
 
78
78
  it "returns attributes in root scope" do
79
- puts subject.inspect
80
79
  expect(subject.to_h["site_name"]).to eq("Sample app")
81
80
  end
82
81
 
data/spec/spec_helper.rb CHANGED
@@ -1,7 +1,7 @@
1
1
  require 'rdm'
2
2
 
3
3
  Rdm.setup do
4
- raises_missing_package_file_exception(false)
4
+ silence_missing_package_file_exception(true)
5
5
  end
6
6
 
7
7
  RSpec.configure do |config|
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rdm
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.1.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Droid Labs
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-03-08 00:00:00.000000000 Z
11
+ date: 2016-03-09 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -136,7 +136,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
136
136
  version: '0'
137
137
  requirements: []
138
138
  rubyforge_project:
139
- rubygems_version: 2.4.3
139
+ rubygems_version: 2.2.2
140
140
  signing_key:
141
141
  specification_version: 4
142
142
  summary: Ruby Dependency Manager