ofx_reader 0.1.1 → 0.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +6 -0
- data/exe/ofx_reader +15 -5
- data/lib/ofx_reader/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ae2436c3f3f0305cbb57d847205d99ea6e71ff0a1394f180b35bf033c59818c1
|
4
|
+
data.tar.gz: 3fd5a2ae1f9ccbe8ca15bd160236c159b583b1e4f0c59b913992631f345c4989
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: e7ae801e9a571dc1c8c122e13a8e2c6e0e1241975ed566fcf469d9afff5df38f2dbbb6abc7730fdc97e4688cb41573a8e37318fcb831bce1413efe9c32c2ddad
|
7
|
+
data.tar.gz: 151e7cb00cbb1d41b570d3ac8a4b89f95434db9820a9aee215153dfdac67758a3834f239194d57c4294628a4ad7ffa4f27896ee3aa8d018f1fe8ba60f0371470
|
data/README.md
CHANGED
@@ -63,6 +63,12 @@ ofx.transactions
|
|
63
63
|
}, ... ]
|
64
64
|
```
|
65
65
|
|
66
|
+
You can also read a .OFX file in console using the `ofx_reader` executable:
|
67
|
+
|
68
|
+
```bash
|
69
|
+
$ ofx_reader path/to/file.ofx
|
70
|
+
```
|
71
|
+
|
66
72
|
## Development
|
67
73
|
|
68
74
|
After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake spec` to run the tests. You can also run `bin/console` for an interactive prompt that will allow you to experiment.
|
data/exe/ofx_reader
CHANGED
@@ -1,8 +1,18 @@
|
|
1
1
|
#!/usr/bin/env ruby
|
2
2
|
|
3
|
-
require
|
4
|
-
require
|
3
|
+
require 'pp'
|
4
|
+
require 'ofx_reader'
|
5
5
|
|
6
|
-
|
7
|
-
|
8
|
-
|
6
|
+
if ARGV[0]
|
7
|
+
if File.exist?(ARGV[0])
|
8
|
+
ofx_text = File.read(ARGV[0])
|
9
|
+
ofx = OFXReader::Parser::OFX102.new(ofx_text)
|
10
|
+
pp ofx.headers
|
11
|
+
pp ofx.account
|
12
|
+
pp ofx.transactions
|
13
|
+
else
|
14
|
+
puts "File doen't exist"
|
15
|
+
end
|
16
|
+
else
|
17
|
+
puts "No file provided"
|
18
|
+
end
|
data/lib/ofx_reader/version.rb
CHANGED