adncv 0.2 → 0.3
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 +4 -4
- data/CHANGELOG.md +13 -0
- data/README.md +8 -2
- data/lib/ADNCV/app.rb +2 -1
- data/lib/ADNCV/data.rb +9 -2
- data/lib/ADNCV/display.rb +12 -0
- data/lib/ADNCV/version.rb +1 -1
- metadata +2 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 35dbb7e2a3ea78edd0e3ddd07d5859d2a95a7ea2
|
4
|
+
data.tar.gz: df4b18cb729f48d9d7902647975074daa36ba660
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 42a8a402031c067812bce3cf5fabdf20fb2f7d7ee9e1a16e12a2c780c2eba611124a06031fe54b461b558cb176a0253327fa1103e64aa6489d750e5765f5b3b7
|
7
|
+
data.tar.gz: ea22e713f23d8efe5d8f0debcf1eaa32a104ef6e7dee59f66095794382151474a839267275fb1ac7a7f9686101dff473fa4a31b1813b827a8d2dd9ab29e54f27
|
data/CHANGELOG.md
ADDED
data/README.md
CHANGED
@@ -1,3 +1,5 @@
|
|
1
|
+
[](http://badge.fury.io/rb/adncv)
|
2
|
+
|
1
3
|
# ADNCV
|
2
4
|
|
3
5
|
Statistics from your App.net data.
|
@@ -11,7 +13,7 @@ Statistics from your App.net data.
|
|
11
13
|
3. Run the Gem on the downloaded file:
|
12
14
|
|
13
15
|
```
|
14
|
-
adncv /path/to/appdotnet-data-you-xxxxx-posts.json
|
16
|
+
adncv -d /path/to/appdotnet-data-you-xxxxx-posts.json
|
15
17
|
```
|
16
18
|
|
17
19
|
## Commands
|
@@ -22,8 +24,12 @@ adncv /path/to/appdotnet-data-you-xxxxx-posts.json
|
|
22
24
|
|
23
25
|
Displays informations.
|
24
26
|
|
27
|
+
Add `-f` for full details (all posted links, mentioned users, etc).
|
28
|
+
|
25
29
|
### Export
|
26
30
|
|
27
31
|
`adncv -e posts.json`
|
28
32
|
|
29
|
-
Exports informations as a JSON file, including all your posted links and mentioned users.
|
33
|
+
Exports informations as a JSON file, including all your posted links and mentioned users.
|
34
|
+
|
35
|
+
Add `-p` to specify the destination folder path (default: in ~).
|
data/lib/ADNCV/app.rb
CHANGED
@@ -15,9 +15,10 @@ module ADNCV
|
|
15
15
|
|
16
16
|
desc "export", "Export your account statistics (-e)"
|
17
17
|
map "-e" => :export
|
18
|
+
option :path, aliases: "-p", type: :string, desc: "Specify the path for the exported file"
|
18
19
|
def export(file)
|
19
20
|
analyze(file)
|
20
|
-
@data.export
|
21
|
+
@data.export(options)
|
21
22
|
@display.exported(@data.export_path)
|
22
23
|
end
|
23
24
|
|
data/lib/ADNCV/data.rb
CHANGED
@@ -73,7 +73,15 @@ module ADNCV
|
|
73
73
|
|
74
74
|
end
|
75
75
|
|
76
|
-
def export
|
76
|
+
def export(options)
|
77
|
+
root = if options["path"]
|
78
|
+
options["path"]
|
79
|
+
else
|
80
|
+
Dir.home
|
81
|
+
end
|
82
|
+
|
83
|
+
@export_path = "#{root}/adncv_export.json"
|
84
|
+
|
77
85
|
export = {
|
78
86
|
meta: {
|
79
87
|
created_at: Time.now,
|
@@ -110,7 +118,6 @@ module ADNCV
|
|
110
118
|
}
|
111
119
|
}
|
112
120
|
|
113
|
-
@export_path = "#{Dir.home}/adncv_export.json"
|
114
121
|
File.write(@export_path, export.to_json)
|
115
122
|
end
|
116
123
|
|
data/lib/ADNCV/display.rb
CHANGED
@@ -6,8 +6,20 @@ module ADNCV
|
|
6
6
|
@thor = Thor::Shell::Color.new
|
7
7
|
end
|
8
8
|
|
9
|
+
def banner
|
10
|
+
<<-ADNCV
|
11
|
+
___ ___ _ ________ __
|
12
|
+
/ _ | / _ \\/ |/ / ___/ | / /
|
13
|
+
/ __ |/ // / / /__ | |/ /
|
14
|
+
/_/ |_/____/_/|_/\\___/ |___/
|
15
|
+
|
16
|
+
ADNCV
|
17
|
+
end
|
18
|
+
|
9
19
|
def version
|
20
|
+
puts banner()
|
10
21
|
@thor.say_status :version, "#{VERSION}", :red
|
22
|
+
puts "\n"
|
11
23
|
end
|
12
24
|
|
13
25
|
def analyzing
|
data/lib/ADNCV/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: adncv
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '0.
|
4
|
+
version: '0.3'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Eric Dejonckheere
|
@@ -62,6 +62,7 @@ extra_rdoc_files: []
|
|
62
62
|
files:
|
63
63
|
- ".gitignore"
|
64
64
|
- ADNCV.gemspec
|
65
|
+
- CHANGELOG.md
|
65
66
|
- Gemfile
|
66
67
|
- LICENSE.txt
|
67
68
|
- README.md
|