fancy_gets 0.1.0 → 0.1.1

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
  SHA1:
3
- metadata.gz: fa82413ae8f11a2c6a6760a5d15d951d6cb77f12
4
- data.tar.gz: 1e5e1b10db12c9b5452ff6e3996ec8fc6cac6d13
3
+ metadata.gz: ff5d475c55794cbbeb171f984781e0e9e953f786
4
+ data.tar.gz: c1ee7c43108ebdee5d411f77ce00adee5979d028
5
5
  SHA512:
6
- metadata.gz: 34acd4801dec89245f9f96c09bcebc00d177c788d1f0daa0f2ce757c8a2dd7055303961caa3ca8ea6b44c1c45090379dd44648306957463f408c3f6bb72bfd1f
7
- data.tar.gz: 119b5775cbc26f3b67d1ca224fc052f6317640e2f1ca7b7c9d0cc33ce87469a1096a8e02cdf65b1f6ee484fd497b233adcf3072d041b0aa00041996c950a134c
6
+ metadata.gz: 55d84b9ec732bcaf7346715fc3708be30480071888dbce1b3a7072ec69c8e44022a45fee5923b0dd0707005df13055603bb0f75507c9721036c0c42e87cdbccc
7
+ data.tar.gz: bfb4ba37970492e8a901cdd09621daa212b0cdae6e9805ab2bb6544c9edbe87a9cc5b3178330f29c08950d57de0f4fabf0c5025c75d8640567b2bd269d7a257f
data/README.md CHANGED
@@ -3,7 +3,7 @@
3
3
  This gem exists to banish crusty UX that our users endure at the command line.
4
4
 
5
5
  For far too long we've been stuck with just gets and getc. When prompting the
6
- user with a list of choices, wouldn't it be nice to have the feel of a <select>
6
+ user with a list of choices, wouldn't it be nice to have the feel of a < select >
7
7
  in HTML? Or to auto-suggest options as they type? Or perhaps offer a password
8
8
  entry with asterisks instead of just sitting silent, which confuses many users?
9
9
 
@@ -63,7 +63,7 @@ Another cool thing this allows is to change the color of selected items. You ma
63
63
  to check out Michał Kalbarczyk's [colorize gem](https://github.com/fazibear/colorize "Michał loves all things \033") for more info.
64
64
 
65
65
  ```ruby
66
- another_toy = gets_list(toys, false, nil, "==>", "<== PARTY TIME!", "Use arrows to pick something awesome.")
66
+ another_toy = gets_list(toys, false, nil, "\033[1;31m", "\033[0m <==", "Use arrows to pick something awesome.")
67
67
  puts "\nSo much to love about #{another_toy}."
68
68
  ```
69
69
 
@@ -1,3 +1,3 @@
1
1
  module FancyGets
2
- VERSION = "0.1.0"
2
+ VERSION = "0.1.1"
3
3
  end
data/lib/fancy_gets.rb CHANGED
@@ -40,7 +40,7 @@ module FancyGets
40
40
 
41
41
  write_sugg = lambda do
42
42
  # Find first word that case-insensitive matches what they've typed
43
- if string.blank?
43
+ if string.empty?
44
44
  sugg = ""
45
45
  else
46
46
  sugg = words.select { |word| uncolor.call(word).downcase.start_with? string.downcase }.first || ""
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fancy_gets
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Lorin Thwaits