coming_soon 0.2.4 → 0.2.5
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/lib/coming_soon/cli.rb +2 -2
- data/lib/coming_soon/movie.rb +3 -2
- data/lib/coming_soon/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 604305adcaced9bcc6b8e032891a5f559278c8a4
|
|
4
|
+
data.tar.gz: 80d9cd8e88840c30f272703f5bda912034cc8fa9
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: b49457dfdfd5e3f3368ccd611fdb13b3d0dc532574bc73dad6924bfc185f5183e32637c587eeb5ba1c6cf4855e5bb415a4af38b148d6402ba6fdc4c217b5e461
|
|
7
|
+
data.tar.gz: 9b6347e5814e553d38859f09751fe181c0ebe696d5570978e86bd4f9a2eb19d0be712c51015e10186c4be62f717eaecebfcae5e8bc4d1b67acd4bb3a53ca99a9
|
data/lib/coming_soon/cli.rb
CHANGED
|
@@ -17,7 +17,7 @@ class ComingSoon::CLI
|
|
|
17
17
|
|
|
18
18
|
@movies = ComingSoon::Movie.movies
|
|
19
19
|
|
|
20
|
-
@movies.each.with_index(1) do |movie, i|
|
|
20
|
+
@movies.each.with_index(1) do |movie, i| # set the first index to 1 and use the index number for the movie number
|
|
21
21
|
puts "#{i}. #{movie.name} - #{movie.start_date}"
|
|
22
22
|
end
|
|
23
23
|
end
|
|
@@ -29,7 +29,7 @@ class ComingSoon::CLI
|
|
|
29
29
|
puts ' **********************'
|
|
30
30
|
puts ''
|
|
31
31
|
|
|
32
|
-
@movies.each.with_index(1) do |movie, i|
|
|
32
|
+
@movies.each.with_index(1) do |movie, i| # set the first index to 1 and use the index number for the movie number
|
|
33
33
|
puts "#{i}. #{movie.name} - #{movie.start_date}"
|
|
34
34
|
end
|
|
35
35
|
end
|
data/lib/coming_soon/movie.rb
CHANGED
|
@@ -21,7 +21,7 @@ class ComingSoon::Movie
|
|
|
21
21
|
@movies = []
|
|
22
22
|
count = 1
|
|
23
23
|
|
|
24
|
-
movie_list.each do |movie|
|
|
24
|
+
movie_list.each do |movie|
|
|
25
25
|
@soon = self.new
|
|
26
26
|
@soon.name = movie.css("a.visual-title").text.strip
|
|
27
27
|
@soon.start_date = movie.css("span").text
|
|
@@ -55,7 +55,8 @@ class ComingSoon::Movie
|
|
|
55
55
|
# present and any text is available, use the text for the synopsis
|
|
56
56
|
@soon.synopsis = @doc_synop1.css("span#SynopsisTextLabel").text
|
|
57
57
|
else
|
|
58
|
-
#
|
|
58
|
+
# Scrape the synopsis using the HTTP 'plotsummary' url
|
|
59
|
+
# This is also executed after an HTTP to HTTPS redirect failed
|
|
59
60
|
synop_url = @soon.url.sub(/movieoverview/, 'plotsummary')
|
|
60
61
|
doc_synop2 = Nokogiri::HTML(open(synop_url))
|
|
61
62
|
@soon.synopsis = doc_synop2.css("p.subpage-descriptive-content").text
|
data/lib/coming_soon/version.rb
CHANGED
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: coming_soon
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.2.
|
|
4
|
+
version: 0.2.5
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Terry Blue
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2017-05-
|
|
11
|
+
date: 2017-05-03 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: rake
|