Skip to content

Commit

Permalink
remove old fx format
Browse files Browse the repository at this point in the history
  • Loading branch information
geraldb committed Aug 15, 2014
1 parent 003f5a5 commit 2f2be04
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 8 deletions.
1 change: 1 addition & 0 deletions lib/sportdb/calc.rb
Expand Up @@ -13,6 +13,7 @@ module StandingsHelper
## todo:
## add team_id to struct - why? why not? - saves a db lookup?
class Stats
### fix/todo: change/rename :pos to :rank
attr_accessor :pos, :played, :won, :lost, :drawn,
:goals_for, :goals_against, :pts,
:recs
Expand Down
11 changes: 3 additions & 8 deletions lib/sportdb/reader.rb
Expand Up @@ -21,14 +21,6 @@ def initialize( include_path, opts={})

def load_setup( name )
path = "#{include_path}/#{name}.txt"

## depcrecated - for now check if "new" format exsits
## - if not fall back to old format
unless File.exists?( path )
puts " deprecated manifest/setup format [SportDb.Reader]; use new plain text format"
## try old yml format
path = "#{include_path}/#{name}.yml"
end

logger.info "parsing data '#{name}' (#{path})..."

Expand All @@ -41,6 +33,9 @@ def load_setup( name )


def is_club_fixture?( name )
### fix: move to attic - no longer needed ??
## - use clubs.txt for clubs; and teams.txt for national teams

## guess (heuristic) if it's a national team event (e.g. world cup, copa america, etc.)
## or club event (e.g. bundesliga, club world cup, etc.)

Expand Down
2 changes: 2 additions & 0 deletions lib/sportdb/schema.rb
Expand Up @@ -300,6 +300,8 @@ def up
t.timestamps
end

### use items instead of entries - why (shorter! simple plural e.g. just add s)

create_table :group_standing_entries do |t|
t.references :group_standing, null: false
t.references :team, null: false
Expand Down

0 comments on commit 2f2be04

Please sign in to comment.