imdb-terminal 0.7.1 → 0.7.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/bin/imdb +14 -12
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b84e11a0d17bc14b014874a8fa6c75b50bc04cd5e7a8d1f4e9b49aaf92b198e2
|
4
|
+
data.tar.gz: 84c9dd19d67e71bd7b5fbf4e1ff2ecb3e7095f8088845ef4d5248fedab98392e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 055fec44532c19465fe0bf5d97ee6b8ae59cdd6281d823739d986cb23c1279346f03b0be8155487ae2f9567c47f996208b5c53147ee0d0abd54be8e3d5498c18
|
7
|
+
data.tar.gz: f399d1825e5c43a165cb045815dce7129b7a6f021ed94bfc98f8797d9794b19147304dcf92e6b593be6874cc5d3e1885d3651e2ac7ebc36a1bad730d9434c84d
|
data/bin/imdb
CHANGED
@@ -14,7 +14,7 @@
|
|
14
14
|
# for any damages resulting from its use. Further, I am under no
|
15
15
|
# obligation to maintain or extend this software. It is provided
|
16
16
|
# on an 'as is' basis without any expressed or implied warranty.
|
17
|
-
@version = "0.7.
|
17
|
+
@version = "0.7.3"
|
18
18
|
|
19
19
|
# PRELIMINARIES
|
20
20
|
@help = <<HELPTEXT
|
@@ -174,13 +174,18 @@ class Curses::Window # CLASS EXTENSION
|
|
174
174
|
self.setpos(y, x)
|
175
175
|
end
|
176
176
|
def p(fg = self.fg, bg = self.bg, attr = self.attr, text) # Puts text to window with full set of attributes
|
177
|
-
fg
|
178
|
-
bg
|
179
|
-
attr = 0
|
180
|
-
cp
|
177
|
+
fg = 255 if fg == nil
|
178
|
+
bg = 0 if bg == nil
|
179
|
+
attr = 0 if attr == nil
|
180
|
+
cp = Curses::Window.pair(fg, bg)
|
181
181
|
self.attron(color_pair(cp) | attr) { self << text }
|
182
182
|
self.refresh
|
183
183
|
end
|
184
|
+
def nl(bg = self.bg)
|
185
|
+
bg = 232 if bg == nil
|
186
|
+
f = " " * (self.maxx - self.curx)
|
187
|
+
self.p(self.fg, bg, self.attr, f)
|
188
|
+
end
|
184
189
|
def format(text) # Format text so that it linebreaks neatly inside window
|
185
190
|
return "\n" + text.gsub(/(.{1,#{self.maxx-1}})( +|$\n?)|(.{1,#{self.maxx-1}})/, "\\1\\3\n")
|
186
191
|
end
|
@@ -539,8 +544,8 @@ def w_t # SHOW INFO IN @w_t
|
|
539
544
|
@w_t.clr
|
540
545
|
@movies ? text = " MOVIES :: " : text = " SERIES :: "
|
541
546
|
text += "Rating MIN: #{@rating} - Year MIN: #{@yearMin} - Year MAX: #{@yearMax} :: Selection = #{@imdbsel.size}"
|
542
|
-
text += " " * (@w_t.maxx - text.length) if text.length < @w_t.maxx
|
543
547
|
@w_t.p(text)
|
548
|
+
@w_t.nl
|
544
549
|
end
|
545
550
|
def w_list(win) # LIST IN WINDOW
|
546
551
|
win.attr = 0
|
@@ -573,9 +578,7 @@ def w_list(win) # LIST IN WINDOW
|
|
573
578
|
str = str[0..(win.maxx - 6)] + "…" if str.length > win.maxx - 4
|
574
579
|
win.p(str)
|
575
580
|
win.attr = 0
|
576
|
-
|
577
|
-
fill = fill[0..-2] if win == @w_g
|
578
|
-
win.p(fill)
|
581
|
+
win.nl
|
579
582
|
ix += 1; t += 1
|
580
583
|
end
|
581
584
|
if win.index > win.maxy/2
|
@@ -673,9 +676,8 @@ def w_b_getstr(pretext, text) # A SIMPLE READLINE-LIKE ROUTINE
|
|
673
676
|
chr = ""
|
674
677
|
while chr != "ENTER"
|
675
678
|
@w_b.setpos(0,0)
|
676
|
-
|
677
|
-
|
678
|
-
@w_b.p(text)
|
679
|
+
@w_b.p(pretext + text)
|
680
|
+
@w_b.nl
|
679
681
|
@w_b.setpos(0,pretext.length + pos)
|
680
682
|
@w_b.refresh
|
681
683
|
chr = getchr
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: imdb-terminal
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.7.
|
4
|
+
version: 0.7.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Geir Isene
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2023-07-
|
11
|
+
date: 2023-07-11 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: curses
|
@@ -48,8 +48,8 @@ description: 'Narrow down your preferences from a 1000 movies and almost 500 ser
|
|
48
48
|
Select a minimum IMDB rating, range of production years, genres you like and dislike
|
49
49
|
to get your preferred list. Get detailed information on movies and series and where
|
50
50
|
you can stream them. Even the movie poster in the terminal. New in 0.2: Added ''v''
|
51
|
-
to show version and RubyGem version. Code cleanup. 0.7:
|
52
|
-
|
51
|
+
to show version and RubyGem version. Code cleanup. 0.7.3: Bug fix on entering text
|
52
|
+
in bottom window.'
|
53
53
|
email: g@isene.com
|
54
54
|
executables:
|
55
55
|
- imdb
|