Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

conform to app generated by template for Rails 3.1.0.rc5

  • Loading branch information...
commit 7c08a19a508c12dea9ac13852f069a039447a38b 1 parent c4e9ea2
@fortuity fortuity authored
View
10 Gemfile
@@ -1,8 +1,10 @@
source 'http://rubygems.org'
-gem 'rails', '3.1.0.rc4'
-gem 'sass-rails', "~> 3.1.0.rc"
-gem 'coffee-script'
-gem 'uglifier'
+gem 'rails', '3.1.0.rc5'
+group :assets do
+ gem 'sass-rails', "~> 3.1.0.rc"
+ gem 'coffee-rails', "~> 3.1.0.rc"
+ gem 'uglifier'
+end
gem 'jquery-rails'
gem "rspec-rails", ">= 2.6.1", :group => [:development, :test]
gem "database_cleaner", ">= 0.6.7", :group => :test
View
110 Gemfile.lock
@@ -1,38 +1,37 @@
GEM
remote: http://rubygems.org/
specs:
- actionmailer (3.1.0.rc4)
- actionpack (= 3.1.0.rc4)
+ actionmailer (3.1.0.rc5)
+ actionpack (= 3.1.0.rc5)
mail (~> 2.3.0)
- actionpack (3.1.0.rc4)
- activemodel (= 3.1.0.rc4)
- activesupport (= 3.1.0.rc4)
+ actionpack (3.1.0.rc5)
+ activemodel (= 3.1.0.rc5)
+ activesupport (= 3.1.0.rc5)
builder (~> 3.0.0)
erubis (~> 2.7.0)
i18n (~> 0.6)
- rack (~> 1.3.0)
- rack-cache (~> 1.0.1)
+ rack (~> 1.3.1)
+ rack-cache (~> 1.0.2)
rack-mount (~> 0.8.1)
rack-test (~> 0.6.0)
- sprockets (~> 2.0.0.beta.10)
- tzinfo (~> 0.3.27)
- activemodel (3.1.0.rc4)
- activesupport (= 3.1.0.rc4)
+ sprockets (~> 2.0.0.beta.12)
+ activemodel (3.1.0.rc5)
+ activesupport (= 3.1.0.rc5)
bcrypt-ruby (~> 2.1.4)
builder (~> 3.0.0)
i18n (~> 0.6)
- activerecord (3.1.0.rc4)
- activemodel (= 3.1.0.rc4)
- activesupport (= 3.1.0.rc4)
- arel (~> 2.1.1)
- tzinfo (~> 0.3.27)
- activeresource (3.1.0.rc4)
- activemodel (= 3.1.0.rc4)
- activesupport (= 3.1.0.rc4)
- activesupport (3.1.0.rc4)
+ activerecord (3.1.0.rc5)
+ activemodel (= 3.1.0.rc5)
+ activesupport (= 3.1.0.rc5)
+ arel (~> 2.1.4)
+ tzinfo (~> 0.3.29)
+ activeresource (3.1.0.rc5)
+ activemodel (= 3.1.0.rc5)
+ activesupport (= 3.1.0.rc5)
+ activesupport (3.1.0.rc5)
multi_json (~> 1.0)
addressable (2.2.4)
- arel (2.1.3)
+ arel (2.1.4)
bcrypt-ruby (2.1.4)
bson (1.3.1)
bson_ext (1.3.1)
@@ -44,14 +43,18 @@ GEM
rack-test (>= 0.5.4)
selenium-webdriver (~> 0.2.0)
xpath (~> 0.1.4)
- childprocess (0.1.9)
+ childprocess (0.2.0)
ffi (~> 1.0.6)
+ coffee-rails (3.1.0.rc.5)
+ actionpack (~> 3.1.0.rc1)
+ coffee-script (>= 2.2.0)
+ railties (~> 3.1.0.rc1)
+ sprockets (>= 2.0.0.beta.9)
coffee-script (2.2.0)
coffee-script-source
execjs
coffee-script-source (1.1.1)
- configuration (1.3.1)
- cucumber (1.0.1)
+ cucumber (1.0.2)
builder (>= 2.1.2)
diff-lcs (>= 1.1.2)
gherkin (~> 2.4.5)
@@ -64,11 +67,11 @@ GEM
database_cleaner (0.6.7)
diff-lcs (1.1.2)
erubis (2.7.0)
- execjs (1.2.0)
+ execjs (1.2.1)
multi_json (~> 1.0)
- factory_girl (2.0.0.rc4)
- factory_girl_rails (1.1.rc1)
- factory_girl (~> 2.0.0.rc)
+ factory_girl (2.0.2)
+ factory_girl_rails (1.1.0)
+ factory_girl (~> 2.0.0)
railties (>= 3.0.0)
faraday (0.6.1)
addressable (~> 2.2.4)
@@ -77,16 +80,14 @@ GEM
ffi (1.0.9)
gherkin (2.4.5)
json (>= 1.4.6)
- hike (1.1.0)
+ hike (1.2.0)
i18n (0.6.0)
jquery-rails (1.0.12)
railties (~> 3.0)
thor (~> 0.14)
json (1.5.3)
json_pure (1.5.3)
- launchy (0.4.0)
- configuration (>= 0.0.5)
- rake (>= 0.8.1)
+ launchy (2.0.3)
mail (2.3.0)
i18n (>= 0.4.0)
mime-types (~> 1.16)
@@ -103,7 +104,7 @@ GEM
rspec (~> 2)
multi_json (1.0.3)
multi_xml (0.2.2)
- multipart-post (1.1.2)
+ multipart-post (1.1.3)
net-ldap (0.2.2)
nokogiri (1.4.7)
oa-basic (0.2.6)
@@ -143,9 +144,9 @@ GEM
oa-more (= 0.2.6)
oa-oauth (= 0.2.6)
oa-openid (= 0.2.6)
- polyglot (0.3.1)
+ polyglot (0.3.2)
pyu-ruby-sasl (0.0.3.3)
- rack (1.3.0)
+ rack (1.3.2)
rack-cache (1.0.2)
rack (>= 0.4)
rack-mount (0.8.1)
@@ -155,19 +156,19 @@ GEM
ruby-openid (>= 2.1.8)
rack-ssl (1.3.2)
rack
- rack-test (0.6.0)
+ rack-test (0.6.1)
rack (>= 1.0)
- rails (3.1.0.rc4)
- actionmailer (= 3.1.0.rc4)
- actionpack (= 3.1.0.rc4)
- activerecord (= 3.1.0.rc4)
- activeresource (= 3.1.0.rc4)
- activesupport (= 3.1.0.rc4)
+ rails (3.1.0.rc5)
+ actionmailer (= 3.1.0.rc5)
+ actionpack (= 3.1.0.rc5)
+ activerecord (= 3.1.0.rc5)
+ activeresource (= 3.1.0.rc5)
+ activesupport (= 3.1.0.rc5)
bundler (~> 1.0)
- railties (= 3.1.0.rc4)
- railties (3.1.0.rc4)
- actionpack (= 3.1.0.rc4)
- activesupport (= 3.1.0.rc4)
+ railties (= 3.1.0.rc5)
+ railties (3.1.0.rc5)
+ actionpack (= 3.1.0.rc5)
+ activesupport (= 3.1.0.rc5)
rack-ssl (~> 1.3.2)
rake (>= 0.8.7)
rdoc (~> 3.4)
@@ -194,8 +195,8 @@ GEM
ruby-openid (>= 2.1.7)
rubyntlm (0.1.1)
rubyzip (0.9.4)
- sass (3.1.4)
- sass-rails (3.1.0.rc.4)
+ sass (3.1.5)
+ sass-rails (3.1.0.rc.5)
actionpack (~> 3.1.0.rc1)
railties (~> 3.1.0.rc1)
sass (>= 3.1.4)
@@ -205,14 +206,15 @@ GEM
ffi (>= 1.0.7)
json_pure
rubyzip
- sprockets (2.0.0.beta.10)
- hike (~> 1.0)
+ sprockets (2.0.0.beta.12)
+ hike (~> 1.2)
rack (~> 1.0)
tilt (!= 1.3.0, ~> 1.1)
- term-ansicolor (1.0.5)
+ term-ansicolor (1.0.6)
thor (0.14.6)
tilt (1.3.2)
- treetop (1.4.9)
+ treetop (1.4.10)
+ polyglot
polyglot (>= 0.3.1)
tzinfo (0.3.29)
uglifier (1.0.0)
@@ -227,7 +229,7 @@ PLATFORMS
DEPENDENCIES
bson_ext (>= 1.3.1)
capybara (>= 1.0.0)
- coffee-script
+ coffee-rails (~> 3.1.0.rc)
cucumber-rails (>= 1.0.2)
database_cleaner (>= 0.6.7)
factory_girl_rails (>= 1.1.rc1)
@@ -236,7 +238,7 @@ DEPENDENCIES
mongoid (>= 2.0.2)
mongoid-rspec (>= 1.4.4)
omniauth (>= 0.2.6)
- rails (= 3.1.0.rc4)
+ rails (= 3.1.0.rc5)
rspec-rails (>= 2.6.1)
sass-rails (~> 3.1.0.rc)
uglifier
View
5 app/assets/stylesheets/home.css.scss
@@ -1,8 +1,3 @@
// Place all the styles related to the home controller here.
// They will automatically be included in application.css.
// You can use Sass (SCSS) here: http://sass-lang.com/
-
-body.home {
- // Add the home class to your body tag
- // Then, place scoped styles here.
-}
View
5 app/assets/stylesheets/users.css.scss
@@ -1,8 +1,3 @@
// Place all the styles related to the users controller here.
// They will automatically be included in application.css.
// You can use Sass (SCSS) here: http://sass-lang.com/
-
-body.users {
- // Add the users class to your body tag
- // Then, place scoped styles here.
-}
View
24 app/models/user.rb
@@ -7,21 +7,17 @@ class User
attr_accessible :provider, :uid, :name, :email
def self.create_with_omniauth(auth)
- begin
- create! do |user|
- user.provider = auth['provider']
- user.uid = auth['uid']
- if auth['user_info']
- user.name = auth['user_info']['name'] if auth['user_info']['name'] # Twitter, Google, Yahoo, GitHub
- user.email = auth['user_info']['email'] if auth['user_info']['email'] # Google, Yahoo, GitHub
- end
- if auth['extra']['user_hash']
- user.name = auth['extra']['user_hash']['name'] if auth['extra']['user_hash']['name'] # Facebook
- user.email = auth['extra']['user_hash']['email'] if auth['extra']['user_hash']['email'] # Facebook
- end
+ create! do |user|
+ user.provider = auth['provider']
+ user.uid = auth['uid']
+ if auth['user_info']
+ user.name = auth['user_info']['name'] if auth['user_info']['name'] # Twitter, Google, Yahoo, GitHub
+ user.email = auth['user_info']['email'] if auth['user_info']['email'] # Google, Yahoo, GitHub
+ end
+ if auth['extra'] && auth['extra']['user_hash']
+ user.name = auth['extra']['user_hash']['name'] if auth['extra']['user_hash']['name'] # Facebook
+ user.email = auth['extra']['user_hash']['email'] if auth['extra']['user_hash']['email'] # Facebook
end
- rescue Exception
- raise Exception, "cannot create user record"
end
end
View
7 config/application.rb
@@ -7,9 +7,10 @@
require "active_resource/railtie"
# # require "rails/test_unit/railtie"
-# If you have a Gemfile, require the gems listed there, including any gems
-# you've limited to :test, :development, or :production.
-Bundler.require(:default, Rails.env) if defined?(Bundler)
+# If you have a Gemfile, require the default gems, the ones in the
+# current environment and also include :assets gems if in development
+# or test environments.
+Bundler.require *Rails.groups(:assets) if defined?(Bundler)
module Rails3MongoidOmniauth
class Application < Rails::Application
View
3  config/environments/production.rb
@@ -14,9 +14,6 @@
# Compress JavaScripts and CSS
config.assets.compress = true
- # Specify the default JavaScript compressor
- config.assets.js_compressor = :uglifier
-
# Specifies the header that your server uses for sending files
# (comment out if your front-end server doesn't support this)
config.action_dispatch.x_sendfile_header = "X-Sendfile" # Use 'X-Accel-Redirect' for nginx
Please sign in to comment.
Something went wrong with that request. Please try again.