Football.db National Team Repos Updated - Gold Cup 2013, Confederations Cup 2013, World Cup Quali 20

Hello,

The plain text football (soccer) teams, fixtures, results and more
that you can read with the Ruby sportdb gem [1] now include more int’l
and continental tournaments in its own repos for easy management and
contributions.

Tournaments include:

  • Gold Cup / Copa de Oro 2013, United States [2]
  • Confederations Cup 2013, Brazil [3]
  • Africa Cup of Nations 2013, South Africa
  • World Cup Brazil 2014 Qualifications

For example, you can read the Gold Cup fixtures using Ruby and Rake:

BUILD_DIR = "./build"

FOOTBALL_DB_PATH = "#{BUILD_DIR}/football.db"

DB_CONFIG = {
  :adapter   =>  'sqlite3',
  :database  =>  FOOTBALL_DB_PATH
}

directory BUILD_DIR

task :env => BUILD_DIR do
  require 'worlddb'
  require 'sportdb'
  require 'logutils/db'

  LogUtils::Logger.root.level = :info

  pp DB_CONFIG
  ActiveRecord::Base.establish_connection( DB_CONFIG )
end

task :create => :env do
  LogDb.create
  WorldDb.create
  SportDb.create
end

task :importworld => :env do
  WorldDb.read_setup( 'setups/sport.db.admin', '../world.db',

skip_tags: true )
# WorldDb.stats
end

task :importsport => :env do
  SportDb.read_builtin
  SportDb.read_setup( 'setups/all', '../openfootball/america-cup' )
  # SportDb.stats
end

desc 'footballdb - build from scratch'
  task :build => [:create, :importworld, :importsport] do
  puts 'Done.'
end

That’s it. More info @ http://openfootball.github.io

Cheers.

[1] GitHub - sportdb/sport.db: sport.db - open sports database (e.g. football.db, formula1.db etc.) command line tool and libraries
[2]
https://github.com/openfootball/america-cup/blob/master/2013/gold.txt
[3]
https://github.com/openfootball/world-cup/blob/master/2013/confed.txt