money 6.9.0 → 6.16.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (47) hide show
  1. checksums.yaml +5 -5
  2. data/CHANGELOG.md +131 -3
  3. data/LICENSE +17 -17
  4. data/README.md +181 -71
  5. data/config/currency_backwards_compatible.json +65 -0
  6. data/config/currency_iso.json +119 -56
  7. data/config/currency_non_iso.json +35 -2
  8. data/lib/money/bank/variable_exchange.rb +22 -12
  9. data/lib/money/currency/loader.rb +15 -13
  10. data/lib/money/currency.rb +38 -39
  11. data/lib/money/locale_backend/base.rb +7 -0
  12. data/lib/money/locale_backend/currency.rb +11 -0
  13. data/lib/money/locale_backend/errors.rb +6 -0
  14. data/lib/money/locale_backend/i18n.rb +25 -0
  15. data/lib/money/locale_backend/legacy.rb +28 -0
  16. data/lib/money/money/allocation.rb +46 -0
  17. data/lib/money/money/arithmetic.rb +33 -15
  18. data/lib/money/money/constructors.rb +1 -2
  19. data/lib/money/money/formatter.rb +399 -0
  20. data/lib/money/money/formatting_rules.rb +142 -0
  21. data/lib/money/money/locale_backend.rb +22 -0
  22. data/lib/money/money.rb +235 -187
  23. data/lib/money/rates_store/memory.rb +24 -24
  24. data/lib/money/version.rb +1 -1
  25. data/money.gemspec +14 -8
  26. metadata +36 -56
  27. data/.coveralls.yml +0 -1
  28. data/.gitignore +0 -23
  29. data/.rspec +0 -1
  30. data/.travis.yml +0 -26
  31. data/AUTHORS +0 -126
  32. data/CONTRIBUTING.md +0 -17
  33. data/Gemfile +0 -16
  34. data/Rakefile +0 -17
  35. data/lib/money/money/formatting.rb +0 -426
  36. data/spec/bank/base_spec.rb +0 -79
  37. data/spec/bank/single_currency_spec.rb +0 -13
  38. data/spec/bank/variable_exchange_spec.rb +0 -265
  39. data/spec/currency/heuristics_spec.rb +0 -11
  40. data/spec/currency/loader_spec.rb +0 -19
  41. data/spec/currency_spec.rb +0 -359
  42. data/spec/money/arithmetic_spec.rb +0 -693
  43. data/spec/money/constructors_spec.rb +0 -103
  44. data/spec/money/formatting_spec.rb +0 -757
  45. data/spec/money_spec.rb +0 -778
  46. data/spec/rates_store/memory_spec.rb +0 -69
  47. data/spec/spec_helper.rb +0 -28
@@ -8,6 +8,7 @@
8
8
  "subunit": "Sent",
9
9
  "subunit_to_unit": 100,
10
10
  "symbol_first": false,
11
+ "format": "%n %u",
11
12
  "html_entity": "",
12
13
  "decimal_mark": ".",
13
14
  "thousands_separator": ",",
@@ -30,6 +31,54 @@
30
31
  "iso_numeric": "288",
31
32
  "smallest_denomination": 1
32
33
  },
34
+ "ltl": {
35
+ "priority": 100,
36
+ "iso_code": "LTL",
37
+ "name": "Lithuanian Litas",
38
+ "symbol": "Lt",
39
+ "alternate_symbols": [],
40
+ "subunit": "Centas",
41
+ "subunit_to_unit": 100,
42
+ "symbol_first": false,
43
+ "format": "%n %u",
44
+ "html_entity": "",
45
+ "decimal_mark": ".",
46
+ "thousands_separator": ",",
47
+ "iso_numeric": "440",
48
+ "smallest_denomination": 1
49
+ },
50
+ "lvl": {
51
+ "priority": 100,
52
+ "iso_code": "LVL",
53
+ "name": "Latvian Lats",
54
+ "symbol": "Ls",
55
+ "alternate_symbols": [],
56
+ "subunit": "Santīms",
57
+ "subunit_to_unit": 100,
58
+ "symbol_first": true,
59
+ "html_entity": "",
60
+ "decimal_mark": ".",
61
+ "thousands_separator": ",",
62
+ "iso_numeric": "428",
63
+ "smallest_denomination": 1
64
+ },
65
+ "mro": {
66
+ "priority": 100,
67
+ "iso_code": "MRO",
68
+ "name": "Mauritanian Ouguiya",
69
+ "symbol": "UM",
70
+ "disambiguate_symbol": "A-UM",
71
+ "alternate_symbols": [],
72
+ "subunit": "Khoums",
73
+ "subunit_to_unit": 5,
74
+ "symbol_first": false,
75
+ "format": "%n %u",
76
+ "html_entity": "",
77
+ "decimal_mark": ".",
78
+ "thousands_separator": ",",
79
+ "iso_numeric": "478",
80
+ "smallest_denomination": 1
81
+ },
33
82
  "mtl": {
34
83
  "priority": 100,
35
84
  "iso_code": "MTL",
@@ -54,6 +103,7 @@
54
103
  "subunit": "Tennesi",
55
104
  "subunit_to_unit": 100,
56
105
  "symbol_first": false,
106
+ "format": "%n %u",
57
107
  "html_entity": "",
58
108
  "decimal_mark": ".",
59
109
  "thousands_separator": ",",
@@ -139,5 +189,20 @@
139
189
  "thousands_separator": ",",
140
190
  "iso_numeric": "935",
141
191
  "smallest_denomination": 100
192
+ },
193
+ "vef": {
194
+ "priority": 100,
195
+ "iso_code": "VEF",
196
+ "name": "Venezuelan Bolívar",
197
+ "symbol": "Bs.F",
198
+ "alternate_symbols": ["Bs"],
199
+ "subunit": "Céntimo",
200
+ "subunit_to_unit": 100,
201
+ "symbol_first": true,
202
+ "html_entity": "",
203
+ "decimal_mark": ",",
204
+ "thousands_separator": ".",
205
+ "iso_numeric": "937",
206
+ "smallest_denomination": 1
142
207
  }
143
208
  }