pointmd_comments 0.1.3 → 0.1.4
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 198cd3c27d299997ca927ded8927ca90390751e51f7c21015b27b871915bfc0e
|
4
|
+
data.tar.gz: 27bb94862cbc8d391c9274fa2e921a10e62adb0d72892a4fb1a0070ec1190e17
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 2cab6853272b96d288ff0ec49b8b3924a884285fde307ecd56549f7d217dda576aa3f5813a85f908ed75c581db4cf2f3ed8d3b1b6d41702554ec81f9af633c1f
|
7
|
+
data.tar.gz: 56235e2eb248b0a2987b296686af0448be815ab0fc805db12cd8e4559ae73f6f8d799ec106494dd7957e324596790b405965391f56c728a981e903a472f02c0b
|
data/bin/pointmd_comments
CHANGED
data/lib/pointmd_comments.rb
CHANGED
@@ -16,7 +16,11 @@ require 'pointmd_comments/errors/unknown_source'
|
|
16
16
|
module PointmdComments
|
17
17
|
class Error < StandardError; end
|
18
18
|
|
19
|
-
def self.collect
|
19
|
+
def self.collect(options = {})
|
20
|
+
Aggregators::Main.new(options).call
|
21
|
+
end
|
22
|
+
|
23
|
+
def self.collect_from_shell
|
20
24
|
args = ARGV.dup
|
21
25
|
options = OptParser.new.parse
|
22
26
|
Aggregators::Main.new(options).call
|
@@ -6,8 +6,8 @@ module PointmdComments
|
|
6
6
|
def initialize(options)
|
7
7
|
# Currently 'path' is not supported
|
8
8
|
@path = nil
|
9
|
-
@output = options[:output]
|
10
|
-
@source = options[:source]
|
9
|
+
@output = options[:output] || default_output_path
|
10
|
+
@source = options[:source] || Aggregators::Posts::DEFAULT_SOURCE
|
11
11
|
@posts_aggregator = Aggregators::Posts.new(source: source, path: path)
|
12
12
|
@comments_aggregator = Aggregators::Comments.new
|
13
13
|
@browser = ::Watir::Browser.new :chrome, headless: true
|
@@ -46,7 +46,7 @@ module PointmdComments
|
|
46
46
|
end
|
47
47
|
|
48
48
|
def write_to_csv
|
49
|
-
file_path = output
|
49
|
+
file_path = output
|
50
50
|
|
51
51
|
CSV.open(file_path, 'w') do |csv|
|
52
52
|
all_comments.each { |c| csv << c }
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: pointmd_comments
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.1.
|
4
|
+
version: 0.1.4
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nicolai Stoianov
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-11-
|
11
|
+
date: 2020-11-14 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: pry
|