lib/crypto_price/cli.rb in crypto_price-0.1.2 vs lib/crypto_price/cli.rb in crypto_price-0.1.3
- old
+ new
@@ -11,29 +11,13 @@
puts "| Current Crypto-Currencies Prices |"
puts "| ================================ |"
puts "| |"
puts "|========================================================================|"
puts "| Today's top Crypto! |"
- puts "|========================================================================|"
- puts "| |"
- puts "| |"
- puts "| Choose an option Number: |"
- puts "| ___________________ |"
- puts "| |"
- puts "| |"
- puts "| |"
- puts "| - 1. Top 10 coins - 2. Top 50 Coins | "
- puts "| |"
- puts "| - 3. exit |"
- puts "| |"
- puts "|________________________________________________________________________|"
- 5.times do
- puts " "
- end
input = nil
- while input != "3"
+ while input != "exit"
puts "|========================================================================|"
puts "| |"
puts "| |"
puts "| Choose an option Number: |"
puts "| ___________________ |"
@@ -57,11 +41,11 @@
when "2"
top_fifty(CryptoPrice::Coin.all)
input = gets.strip
d = CryptoPrice::Coin.all[input.to_i]
show_info(input, d)
- when "3"
+ when "exit"
5.times do
puts " "
end
puts "Have a good day!"
5.times do
@@ -69,10 +53,10 @@
end
else
5.times do
puts " "
end
- puts "Try a valid number"
+ puts "Type 'Exit' when you are done!"
end
end
end
def individual(index, coin)
\ No newline at end of file