libri 0.2.6 → 0.2.7
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/Gemfile.lock +1 -1
- data/lib/libri/cli.rb +2 -2
- data/lib/libri/scraper.rb +0 -1
- data/lib/libri/version.rb +1 -1
- metadata +1 -4
- data/libri-0.2.2.gem +0 -0
- data/libri-0.2.3.gem +0 -0
- data/libri-0.2.4.gem +0 -0
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: fc2ff117a1f3b747599e867774d26147e6bfab632447d14801ae7f9ffd12ba93
|
|
4
|
+
data.tar.gz: dde027bacf13b3b91e4b0156ba6c15fd73e6f86d2238e63e1a6b6504aa842da2
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 86be88a89cfb44f79902109ab542c6ea73bc0940e1093970066593d3ca1cdb69d37136c4bad6f9c6bfdd704f35e39975b1457e971d0598c5f1098cdff9ccf26c
|
|
7
|
+
data.tar.gz: 859a9001d49189d47bb00525a33e973dcf132192fdd52a667c9a157ba4db0db85bcea6cb1b08729e71969401b1b24cadc2df3a012219c83ac673a623c51c4f95
|
data/Gemfile.lock
CHANGED
data/lib/libri/cli.rb
CHANGED
|
@@ -73,7 +73,7 @@ class Libri::CLI
|
|
|
73
73
|
puts
|
|
74
74
|
|
|
75
75
|
if !info.excerpt.nil?
|
|
76
|
-
puts "An excerpt of this book is available. Would you like to read it? (Yn)"
|
|
76
|
+
puts "An excerpt of this book is available. Would you like to read it? (Yn)".blue
|
|
77
77
|
input = STDIN.gets.strip.downcase
|
|
78
78
|
if input == "y"
|
|
79
79
|
puts
|
|
@@ -82,7 +82,7 @@ class Libri::CLI
|
|
|
82
82
|
puts "#{info.excerpt.slice(1..1000)}..."
|
|
83
83
|
puts
|
|
84
84
|
else
|
|
85
|
-
|
|
85
|
+
nil
|
|
86
86
|
end
|
|
87
87
|
end
|
|
88
88
|
end
|
data/lib/libri/scraper.rb
CHANGED
|
@@ -46,7 +46,6 @@ class Libri::Scraper
|
|
|
46
46
|
:blurbs_and_plot => info_section.css("div#productInfoOverview p").map(&:text).join("\n").strip,
|
|
47
47
|
:about_author => info_section.css("div#MeetTheAuthor div.text--medium").text.strip,
|
|
48
48
|
:excerpt => info_section.css("div.read-an-excerpt p").text,
|
|
49
|
-
# info_section.xpath("//div[@class='read-an-excerpt']/p[not(@class) and position()<3]").map(&:text).join("\n"),
|
|
50
49
|
:availability => book_page.css("button#pdp-marketplace-btn").text.chomp,
|
|
51
50
|
:url => book.url
|
|
52
51
|
}.delete_if { |key, val| val.to_s.strip.empty? }
|
data/lib/libri/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: libri
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.7
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- jouissances
|
|
@@ -141,9 +141,6 @@ files:
|
|
|
141
141
|
- lib/libri/quote.rb
|
|
142
142
|
- lib/libri/scraper.rb
|
|
143
143
|
- lib/libri/version.rb
|
|
144
|
-
- libri-0.2.2.gem
|
|
145
|
-
- libri-0.2.3.gem
|
|
146
|
-
- libri-0.2.4.gem
|
|
147
144
|
- libri.gemspec
|
|
148
145
|
- spec.md
|
|
149
146
|
homepage: https://rubygems.org
|
data/libri-0.2.2.gem
DELETED
|
Binary file
|
data/libri-0.2.3.gem
DELETED
|
Binary file
|
data/libri-0.2.4.gem
DELETED
|
Binary file
|