fx_lib 0.1.3 → 0.1.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.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/README.md +10 -3
  3. data/lib/fx_lib/version.rb +1 -1
  4. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 6c6e936eff076ca680c53ee11cd18101d22b69b0
4
- data.tar.gz: f6e8d59edabfcbc043fc991b43190a4fe7fb2471
3
+ metadata.gz: 8b406394b9aa855e1e42a9e5299fffad3870e2ef
4
+ data.tar.gz: ec8c7bc219b8c16646d128e67372f3907e31dcac
5
5
  SHA512:
6
- metadata.gz: e5742eec3712897fd9c2f1d6293615135b604b7cea21fd1dc3308b439fd324a56369efe183df379c901f4f3d5d55d189fa7ddd3670b20843906fa231b03a66b6
7
- data.tar.gz: 566693ca19eb49c85e30f83f0f7a73ca047c7da9b26fead553aee1a355a67b896fa5365fafa163be37415dafa8fe1260f5795c5536237c1b4dc7877111710e95
6
+ metadata.gz: 08e5ef887a5ded25f8d640f510e8f1385b483ea31cb2db245e3761a0da6e7ceb29785969c61f68210c8270d855249381e996c78ff711d0b052a1f741f0df9bd5
7
+ data.tar.gz: 259994d47c491443c457aac1cc9b7d9675c0c723b12bc3044048f4a9f97c318a5ff6f24c69087a257ab20050ae3d75b116a9e190dd9d57946d7179e41c64a37c
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # FxLib
2
2
 
3
- TODO: Write a gem description
3
+ FxLib pull foreign exchange rates from xml feed and store it in a table and provides exchange ratesconversion method
4
4
 
5
5
  ## Installation
6
6
 
@@ -10,7 +10,11 @@ Add this line to your application's Gemfile:
10
10
 
11
11
  And then execute:
12
12
 
13
- $ bundle
13
+ $ rails generate fx_lib:migration
14
+
15
+ To seed the database with current fx rates from xml file please run the following rake task
16
+
17
+ $ rake FX_URL="Your url to the xml file" fx_lib:db_seed
14
18
 
15
19
  Or install it yourself as:
16
20
 
@@ -18,7 +22,10 @@ Or install it yourself as:
18
22
 
19
23
  ## Usage
20
24
 
21
- TODO: Write usage instructions here
25
+ Methods:
26
+ `FxLib::Exchange_Rate.at(Date, Base currency, Counter currency)`
27
+ `FxLib::fetch_data_on(URL, Date)` - Fetch data for a particular date - cron jobs
28
+ `FxLib::fetch_data(URL)` - Fetch, parse, store the feed
22
29
 
23
30
  ## Contributing
24
31
 
@@ -1,3 +1,3 @@
1
1
  module FxLib
2
- VERSION = "0.1.3"
2
+ VERSION = "0.1.4"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fx_lib
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.3
4
+ version: 0.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - hsu