hof_stats 0.1.2 → 0.1.3

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
  SHA1:
3
- metadata.gz: 0af5b08e65d9347908e2ef9ae4cb76748e5374b9
4
- data.tar.gz: 37f8ad3b5657f76c6f4c9f2c3454da5fe8a669e9
3
+ metadata.gz: 8d2acae9e87552baaa1fc1f84be8e74afc04f41b
4
+ data.tar.gz: cd8f71c68ee51f66cbe4cde328af291d779962dd
5
5
  SHA512:
6
- metadata.gz: ab8f4364e806f97cf183820b5022f56e77b47100395471379cb9572195721d6839674f122c8aa83c3311b6a96949c3be9db10f4ccc5988ce4c44d0cfb44b620a
7
- data.tar.gz: 4faed3f8db0ea6b3b2b7669a14a99a3ef47b96b76182b11c144ef9fe990c290d7eac0699a4019577dfe186870ce4d2723d67f04a702f35448f443ee9db2cea65
6
+ metadata.gz: ca72eaab3ed62b3b248f7fa181e1b271a913d2c0df55a0943356dc67ed88db673d321f81ae77c06b27a9959b606faa4a3def57d77ddfc4c2ce63f89177dcab39
7
+ data.tar.gz: 394f63ef69d2f4a77043bf0dc5625d500bea9003d52ba852c549b88262396b7c57c030bb91e708b63a611b733b2061ddb72537f4328bacba6f27578847bce6fc
Binary file
data/lib/hof_stats/cli.rb CHANGED
@@ -11,6 +11,12 @@ class HofStats::CLI
11
11
  puts "MLB Hall of Famers"
12
12
  @players = HofStats::Player.all
13
13
  @players.each_with_index do |player, i|
14
+ if player.votes == ""
15
+ player.votes = "N/A"
16
+ end
17
+ if player.percent == ""
18
+ player.percent = "N/A"
19
+ end
14
20
  puts "#{i+1}. #{player.name} - #{player.year} - #{player.votes} votes - #{player.percent}%"
15
21
  end
16
22
  end
@@ -1,3 +1,3 @@
1
1
  module HofStats
2
- VERSION = "0.1.2"
2
+ VERSION = "0.1.3"
3
3
  end
data/spec.md CHANGED
@@ -2,6 +2,11 @@
2
2
 
3
3
  Specs:
4
4
  - [x] Have a CLI for interfacing with the application
5
- - [ ] Pull data from an external source
6
- - [ ] Implement both list and detail views
5
+ - I created a CLI that first displays a list of all of the members of the MLB hall of fame along with the year they were voted in, how many votes they received, etc. Then, users are allowed to select a player by line number to view career statistics about each player.
6
+
7
+ - [x] Pull data from an external source
8
+ - I am scraping data from the website www.baseball-reference.com.
9
+
10
+ - [x] Implement both list and detail views
11
+ - The list view shows a list of all players in the hall of fame upon running the app. Then, a user can view the detail view for any player by typing their line number. The detail view shows statistics such as career hits, home runs, and batting average for position players, and pitching statistics for pitchers.
7
12
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: hof_stats
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.1.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tony Mastrorio
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-08-19 00:00:00.000000000 Z
11
+ date: 2017-08-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
@@ -99,6 +99,7 @@ files:
99
99
  - bin/hof_stats
100
100
  - bin/setup
101
101
  - hof_stats-0.1.1.gem
102
+ - hof_stats-0.1.2.gem
102
103
  - hof_stats.gemspec
103
104
  - lib/hof_stats.rb
104
105
  - lib/hof_stats/cli.rb