fxpotato 0.2.4 → 0.2.5

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: 6796905596542f38df7dbe3a0afc16c0244fd80c
4
- data.tar.gz: 841a477e2d0a26edce06c98f5b86d629e1578129
3
+ metadata.gz: 96bf1466205c0392c90b1ba4756c74b9a54d674f
4
+ data.tar.gz: 8db3edee83c0397ed6802bcdaf0d5242e74e4449
5
5
  SHA512:
6
- metadata.gz: 6a9544072ae057ad9ede3adb84f368be7c68f911f7781725179859dce7f80fbf5df879f011bf3512a2c18c5e0534a3e34fba848eb15f05b1860edb3113df03d9
7
- data.tar.gz: 1fb85c75a4e95c3070b52f56c147b3d879d1c7c20164af2bad7293b0d9723575fd524a2490bf222b3f8c46c6d8664eb9a7a1537f754c6160c14ac9f31235cff9
6
+ metadata.gz: d334930ca7e6a9c78bed5abbf01aea3ecd4475d6109ae5626c9f67d563a998a924809b99011eb14eea2068f126c9c265833be9ec54a052d5a150f3c9181d44ad
7
+ data.tar.gz: 34a0381d4baf8ad59f18143e075fbcc5e51ca1e47383411124fc3827d9eb7f311a1b855c22c99eae1dc710e466508e73e131b8497a7ae01adf709ea9747192be
data/lib/fxpotato/cli.rb CHANGED
@@ -3,9 +3,10 @@ require 'fxpotato'
3
3
 
4
4
  module FxPotato
5
5
  class CLI < Thor
6
- desc "getrate DATE FROM_CURRENCY TO_CURRENCY", "Gets the foreign exchange rate for the given currencies on the chosen date."
7
- def getrate(date, from, to)
8
- puts FxPotato.at(date, from, to)
6
+ desc "getrate BASE TARGET", "Gets the foreign exchange rate for the given currencies on the chosen date."
7
+ method_option :date, :aliases => "-d"
8
+ def getrate(base, target)
9
+ puts FxPotato.at(options[:date] || Date.today, base, target)
9
10
  end
10
11
  end
11
12
  end
@@ -1,3 +1,3 @@
1
1
  module FxPotato
2
- VERSION = '0.2.4'
2
+ VERSION = '0.2.5'
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.2.4
4
+ version: 0.2.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Liam Stupid Name Humphreys