ruby-tapas-downloader 1.0.1 → 1.0.2

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: 5cca06220dad1b22ec9ac237334ff1f860674e68
4
- data.tar.gz: a9392d4d857a3fcd85257c9cdcb5bae7532e9f0a
3
+ metadata.gz: ead20e84b9acad5174d882fd8df88d0500ed9ea6
4
+ data.tar.gz: 575b76bd539f6bf27f80fda9b9640ba890db4bc4
5
5
  SHA512:
6
- metadata.gz: 00ebe03a4463feb0b9168118b0cbdc2ef66cafb3ccc14f6316a3fe17463fa40368b9d585019644e4aaf0fa1d5409149e722e61920315babff495164d2772caf8
7
- data.tar.gz: 5d10b7bcb522279593ccf512b002b614d3aea17eb78a64d62cd2d6fe49c6f22da9ecbbac3e763baa4fcf5369edfd266d84378e0819564f7daf7c0809286ae28e
6
+ metadata.gz: 82921b9f4ec176dfdd797212b711c1466c17fbfc4d5f9f47d8f73495e6a43fdec71fba4a98ab11a396f460b3179d1a60dbba36ddae345f965d93816e8271b71d
7
+ data.tar.gz: 955b4d6aaeff3c24251281d25a693c88b214d85e79fb1efdc630047d5624858992a39228391f2015cdf9d3ae43c3eb6e334df872abbeeb88624ff89f635d708f
@@ -5,6 +5,7 @@ require 'rexml/document'
5
5
  require 'set'
6
6
  require 'cgi'
7
7
  require 'logger'
8
+ require 'pathname'
8
9
 
9
10
  module RubyTapasDownloader
10
11
  class << self
@@ -1,8 +1,16 @@
1
1
  # Retrieve configurations.
2
2
  class RubyTapasDownloader::Config
3
- # Retrieve urls stored in `urls.yml`.
4
- # @return [Hash] the urls stored in `urls.yml`.
5
- def self.urls
6
- @urls ||= YAML.load File.read 'config/urls.yml'
3
+ class << self
4
+ # Retrieve urls stored in `urls.yml`.
5
+ # @return [Hash] the urls stored in `urls.yml`.
6
+ def urls
7
+ @urls ||= YAML.load_file urls_config_path
8
+ end
9
+
10
+ private
11
+
12
+ def urls_config_path
13
+ Pathname File.expand_path('../../../config/urls.yml', __FILE__)
14
+ end
7
15
  end
8
16
  end
@@ -1,3 +1,3 @@
1
1
  module RubyTapasDownloader
2
- VERSION = '1.0.1'
2
+ VERSION = '1.0.2'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ruby-tapas-downloader
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.1
4
+ version: 1.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Leandro Facchinetti