fxpotato 0.5.3 → 0.5.4

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: 17c4d43526292683b8500eaf7d4f148f75d60bec
4
- data.tar.gz: 9233ead98526c43c490d9af1911c10dbbedb78c9
3
+ metadata.gz: f71e0c0729856a7607ba7a5c5a2578d2020a6f15
4
+ data.tar.gz: 1c9bd0562e4de97bc7b38ed44342431a61239595
5
5
  SHA512:
6
- metadata.gz: 4f2eb7acd08f4b6a396ddf53d19830a80865a4435dbf7f3ab2fbc35519dcc60733325079dd35a1b7011cebc9cfc95007d6d13c620ea2a1e6f65604be0f57d761
7
- data.tar.gz: d1bd20df94078d580c78a23b6be27c42c2dbf9cee841fe154336bd5ab0a719ddfffacade69e4cb34aaa18b531d6b95ca9546bafb5bff549e9a9b39849b64f7e0
6
+ metadata.gz: f87b628056773e8252186cf0181461584e8005b0aa8957b3710ef18f0d04cc357cdb756387432ff4da941e12c4f28f3aaf18f3ad332deeb36b47ccf59687ce3a
7
+ data.tar.gz: e80141e09791203132db57663f2fbfee7ac7cd8800d155a11ddbc6085beee88a030ed7f7c8711f816795e9dbfe80161b6f48b956feddf599fb2a7b61b1a239ad
data/Rakefile CHANGED
@@ -9,16 +9,6 @@ Rake::TestTask.new(:unit_test) do |t|
9
9
  t.test_files = FileList['test/**/*_test.rb']
10
10
  end
11
11
 
12
- desc "Clear crontab"
13
- task :clear_crontab do
14
- sh %{ whenever -c }
15
- end
16
-
17
- desc "Download new exchange rate data"
18
- task :fetch_new_rates do
19
- FxPotato.fetch_new_rates
20
- end
21
-
22
12
  desc "Bump version and release gem"
23
13
  task :bump_release do
24
14
  sh %{ gem bump && rake release }
@@ -1,5 +1,5 @@
1
1
  module FxPotato
2
- DATA_DIRECTORY = defined?(Rails) ? File.join(Rails.root, "data") : File.join(File.expand_path(File.dirname(__FILE__) + "/../../"), "data")
2
+ DATA_DIRECTORY = File.join(File.expand_path(File.dirname(__FILE__) + "/../../"), "data")
3
3
  DATA_FILE = 'rates.xml'
4
4
  DATA_SOURCE_URL = 'http://www.ecb.europa.eu/stats/eurofxref/eurofxref-hist-90d.xml'
5
5
  end
@@ -1,7 +1,13 @@
1
- class FxPotato::Railtie < Rails::Railtie
2
- rake_tasks do
3
- load 'tasks/fetch_new_rates.rake'
4
- load 'tasks/update_crontab.rake'
5
- load 'tasks/clear_crontab.rake'
1
+ module FxPotato
2
+ class Railtie < Rails::Railtie
3
+ rake_tasks do
4
+ load 'tasks/fetch_new_rates.rake'
5
+ load 'tasks/update_crontab.rake'
6
+ load 'tasks/clear_crontab.rake'
7
+ end
8
+
9
+ config.after_initialize do
10
+ DATA_DIRECTORY = File.join(Rails.root, "data")
11
+ end
6
12
  end
7
13
  end
@@ -1,3 +1,3 @@
1
1
  module FxPotato
2
- VERSION = '0.5.3'
2
+ VERSION = '0.5.4'
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fxpotato
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.5.3
4
+ version: 0.5.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Liam Stupid Name Humphreys