pokedex-terminal 0.1.1 → 0.1.2

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6fa160440216b86a7278ccd1e9bd623388c2479c46207f4135e5e6d779ce16f3
4
- data.tar.gz: 9c3ce75d51612d4c232c37fac4eb503af06d1fecd3b7a1886265a4acb0894ba4
3
+ metadata.gz: 360fced44a71058bcaec8c07f2a57d3f8b9cb2330dfb55a072f5a7dde6ea0685
4
+ data.tar.gz: 875cc3ace591042a18a1ce859c2f41a4b66585a9243866724a9266172f35629f
5
5
  SHA512:
6
- metadata.gz: e9458a03eb4a6f6a8f9d5e9ce6ed385c1e34b22d089e3404f5495b8bbb48ac61bceb7329250a70a9a023b96cfdda2056b946d602b7efbb6f63795528769a55d2
7
- data.tar.gz: a234ef28272181c616bca2f3971deda8629528ba917bf7203046e9d1ca116d65371775abdd1557abef045a455e4e376ad1ed32e520a6fdbaf8117ce682adeeb2
6
+ metadata.gz: 264dda2ae2c32b2313d881af00aeaad9082e249d0a5e7f37b96aba54fb540569d7022438dc8129fd6051713e3c89b63851685790dfd2301342f5e472077c2508
7
+ data.tar.gz: c6655af403379e18d83c53caadf5e129a0b7f819b4cbe53dfad12a362696c76006ce19d2cca0d835c9cb0fa72dd29a74b1863fb997612b86d1603f21d6327bd7
data/Gemfile.lock CHANGED
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- pokedex-terminal (0.1.1)
4
+ pokedex-terminal (0.1.2)
5
5
 
6
6
  GEM
7
7
  remote: https://rubygems.org/
data/bin/console CHANGED
@@ -1,7 +1,7 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
3
  require "bundler/setup"
4
- require "pokedex/terminal"
4
+ require "terminal"
5
5
 
6
6
  # You can add fixtures and/or initialization code here to make experimenting
7
7
  # with your gem easier. You can also use a different console, if you like.
data/bin/pokedex-terminal CHANGED
@@ -1,5 +1,3 @@
1
1
  #!/usr/bin/env ruby
2
2
 
3
- require "pokedex/terminal"
4
-
5
- Main_menu.run
3
+ require_relative "../lib/pokedex-terminal"
File without changes
@@ -4,6 +4,7 @@ class List
4
4
 
5
5
  def self.list_menu(data)
6
6
  while true
7
+ system 'clear'
7
8
  list_prompt = TTY::Prompt.new(active_color: :red)
8
9
  user_input = list_prompt.select("How would you like to list the Pokemon?\nPlease enter one of the following options.") do |menu|
9
10
  menu.choice "List all", 1
@@ -5,15 +5,17 @@ require_relative './List'
5
5
  require_relative './Delete'
6
6
  require 'tty-prompt'
7
7
  require 'smarter_csv'
8
+ require 'artii'
9
+ require 'lolize'
8
10
 
9
11
  class Main_menu
10
12
  @@pokemon_data = SmarterCSV.process('../../data/pokemon.csv')
11
13
 
12
14
  def self.run
13
15
  while true
16
+ fork{exec "artii './titlesequence.plaintext' --font larry3d | lolcat"}
14
17
  main_menu_prompt = TTY::Prompt.new(active_color: :red)
15
18
  puts "-" * 40
16
- # main_menu_prompt.warn(" Welcome to your Pokedex!")
17
19
  puts " Welcome to your Pokedex! ".blue.on_red.blink
18
20
  puts "-" * 40
19
21
  user_input = main_menu_prompt.select("Please select from the following:") do |menu|
@@ -27,6 +29,7 @@ class Main_menu
27
29
  end
28
30
  case user_input
29
31
  when 1
32
+
30
33
  List.list_menu(@@pokemon_data)
31
34
  when 2
32
35
  name = Search.by_name(@@pokemon_data)
File without changes
@@ -4,6 +4,7 @@ require 'colorize'
4
4
  class Print
5
5
 
6
6
  def self.print_pokemon_expanded(hash)
7
+ system 'clear'
7
8
  puts "-" * 40
8
9
  puts "#{hash[:name]}"
9
10
  puts "-" * 40
@@ -27,6 +28,7 @@ class Print
27
28
  end
28
29
 
29
30
  def self.print_pokemon_condensed(hash)
31
+ system 'clear'
30
32
  name = "#{hash[:name]}"
31
33
  case hash[:type_1]
32
34
  when "Normal"
File without changes
File without changes
@@ -0,0 +1,6 @@
1
+ require_relative 'classes/Main_menu'
2
+
3
+ fork{exec "artii './titlesequence.plaintext' --font larry3d | lolcat -a -d 15"}
4
+ sleep(10)
5
+ system 'clear'
6
+ Main_menu.run
@@ -1,5 +1,5 @@
1
1
  module Pokedex
2
2
  module Terminal
3
- VERSION = "0.1.1"
3
+ VERSION = "0.1.2"
4
4
  end
5
5
  end
File without changes
@@ -1,4 +1,4 @@
1
- require_relative 'lib/pokedex/terminal/version'
1
+ require_relative 'lib/terminal/version'
2
2
 
3
3
  Gem::Specification.new do |spec|
4
4
  spec.name = "pokedex-terminal"
@@ -11,7 +11,8 @@ Gem::Specification.new do |spec|
11
11
  spec.homepage = "https://rubygems.org/gems/pokedex-terminal"
12
12
  spec.license = "GPL-3.0-or-later"
13
13
  spec.required_ruby_version = Gem::Requirement.new(">= 2.3.0")
14
-
14
+ spec.executables = ["pokedex-terminal"]
15
+ spec.require_paths = ["lib"]
15
16
  # spec.metadata["allowed_push_host"] = "TODO: Set to 'http://mygemserver.com'"
16
17
 
17
18
  # spec.metadata["homepage_uri"] = spec.homepage
@@ -23,8 +24,7 @@ Gem::Specification.new do |spec|
23
24
  spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
24
25
  `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
25
26
  end
26
- spec.bindir = "exe"
27
- spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
27
+ spec.executables = ["pokedex-terminal"]
28
28
  spec.require_paths = ["lib"]
29
29
  spec.add_development_dependency 'colorize', '~> 0.8.1'
30
30
  spec.add_development_dependency 'smarter_csv', '~> 1.1', '>= 1.1.4'
metadata CHANGED
@@ -1,12 +1,12 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: pokedex-terminal
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - nova
8
8
  autorequire:
9
- bindir: exe
9
+ bindir: bin
10
10
  cert_chain: []
11
11
  date: 2020-03-12 00:00:00.000000000 Z
12
12
  dependencies:
@@ -101,7 +101,8 @@ dependencies:
101
101
  description: Pokedex in terminal with CRUD functionality.
102
102
  email:
103
103
  - alexander.coole@protonmail.com
104
- executables: []
104
+ executables:
105
+ - pokedex-terminal
105
106
  extensions: []
106
107
  extra_rdoc_files: []
107
108
  files:
@@ -118,19 +119,17 @@ files:
118
119
  - bin/pokedex-terminal
119
120
  - bin/setup
120
121
  - data/pokemon.csv
121
- - lib/pokedex/classes/Delete.rb
122
- - lib/pokedex/classes/List.rb
123
- - lib/pokedex/classes/Main_menu.rb
124
- - lib/pokedex/classes/New.rb
125
- - lib/pokedex/classes/Pokemon.rb
126
- - lib/pokedex/classes/Print.rb
127
- - lib/pokedex/classes/Search.rb
128
- - lib/pokedex/classes/Update.rb
129
- - lib/pokedex/terminal.rb
130
- - lib/pokedex/terminal.rb.save
131
- - lib/pokedex/terminal/version.rb
132
- - lib/pokedex/test.rb
133
- - lib/pokedex/titlesequence.plaintext
122
+ - lib/classes/Delete.rb
123
+ - lib/classes/List.rb
124
+ - lib/classes/Main_menu.rb
125
+ - lib/classes/New.rb
126
+ - lib/classes/Print.rb
127
+ - lib/classes/Search.rb
128
+ - lib/classes/Update.rb
129
+ - lib/pokemon-terminal.rb
130
+ - lib/terminal/version.rb
131
+ - lib/test.rb
132
+ - lib/titlesequence.plaintext
134
133
  - pokedex-terminal.gemspec
135
134
  homepage: https://rubygems.org/gems/pokedex-terminal
136
135
  licenses:
@@ -1,16 +0,0 @@
1
- class Pokemon
2
- def initialize(hash)
3
- @name = hash[:name]
4
- @type_1 = hash[:type_1]
5
- @type_2 = hash[:type_2]
6
- @total = hash[:total]
7
- @hp = hash[:hp]
8
- @attack = hash[:attack]
9
- @defense = hash[:defense]
10
- @sp_atk = hash[:"sp._atk"]
11
- @sp_def = hash[:"sp._def"]
12
- @speed = hash[:speed]
13
- @generation = hash[:generation]
14
- @legendary = hash[:legendary]
15
- end
16
- end
@@ -1,6 +0,0 @@
1
- require_relative 'classes/Main_menu'
2
-
3
- fork{exec "artii 'Pokedex' --font larry3d | lolcat -a -d 15"}
4
- sleep(10)
5
-
6
- Main_menu.run
@@ -1,8 +0,0 @@
1
- rsfsdfsequire 'smarter_csv'
2
- require 'colorize'
3
- require_relative 'classes/Main_menu'
4
-
5
- fork{exec "artii 'Michael' --font larry3d | lolcat -a -d 15"}
6
- sleep(10)
7
-
8
- Main_menu.run