Permalink
Browse files

Switched from SQLite to YAML

  • Loading branch information...
1 parent 05ad22a commit 36ccc8432a05642dd43c8ccef1ce1127443aaef6 @DanielVartanov committed Mar 10, 2012
Showing with 2,124 additions and 49 deletions.
  1. +1 −2 Gemfile
  2. +4 −18 Gemfile.lock
  3. +1 −5 application.rb
  4. +931 −0 data/prices.yml
  5. +1,152 −0 data/zones.yml
  6. BIN express-taxi.db
  7. +1 −1 kaisy_taxi.rb
  8. +4 −4 lib/price.rb
  9. +5 −5 lib/prices.rb
  10. +0 −11 lib/vertex.rb
  11. +11 −0 lib/yaml_storage.rb
  12. +14 −3 lib/zone.rb
View
@@ -2,8 +2,7 @@ source :rubygems
gem "sinatra"
gem "slim"
-gem "activerecord"
-gem "sqlite3"
+gem "active_support"
gem "ruby-geometry", :require => "geometry"
gem "roo"
gem "nokogiri"
View
@@ -1,21 +1,11 @@
GEM
remote: http://rubygems.org/
specs:
- activemodel (3.1.1)
- activesupport (= 3.1.1)
- builder (~> 3.0.0)
- i18n (~> 0.6)
- activerecord (3.1.1)
- activemodel (= 3.1.1)
- activesupport (= 3.1.1)
- arel (~> 2.2.1)
- tzinfo (~> 0.3.29)
- activesupport (3.1.1)
- multi_json (~> 1.0)
+ active_support (3.0.0)
+ activesupport (= 3.0.0)
+ activesupport (3.0.0)
addressable (2.2.6)
- arel (2.2.1)
awesome_print (0.4.0)
- builder (3.0.0)
choice (0.1.4)
faraday (0.7.5)
addressable (~> 2.2.6)
@@ -25,7 +15,6 @@ GEM
nokogiri (>= 1.4.3.1)
oauth (>= 0.3.6)
oauth2 (>= 0.5.0)
- i18n (0.6.0)
log4r (1.1.10)
multi_json (1.0.3)
multipart-post (1.1.4)
@@ -60,18 +49,16 @@ GEM
tilt (~> 1.3.2)
spreadsheet (0.6.5.9)
ruby-ole (>= 1.0)
- sqlite3 (1.3.4)
temple (0.3.4)
tilt (1.3.3)
todonotes (0.1.0)
log4r
- tzinfo (0.3.30)
PLATFORMS
ruby
DEPENDENCIES
- activerecord
+ active_support
awesome_print
nokogiri
rack-mobile-detect
@@ -80,4 +67,3 @@ DEPENDENCIES
shotgun
sinatra
slim
- sqlite3
View
@@ -1,11 +1,10 @@
require "sinatra"
require "slim"
require "json"
-require "active_record"
-require "sqlite3"
require "logger"
require "awesome_print"
require "pp"
+require "yaml"
require "geometry"
require "rack/mobile-detect"
@@ -17,9 +16,6 @@
Slim::Engine.set_default_options :pretty => true
Slim::Engine.default_options[:disable_escape] = true
-ActiveRecord::Base.logger = Logger.new(STDOUT)
-ActiveRecord::Base.establish_connection :adapter => 'sqlite3', :database => 'express-taxi.db', :pool => 25
-
get '/' do
unless env["X_MOBILE_DEVICE"].nil?
slim :mobile, :layout => false
Oops, something went wrong.

0 comments on commit 36ccc84

Please sign in to comment.