Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Upgrade to Rails 3.1, no tests

  • Loading branch information...
commit e47522781a5ace8c651dc28722498a47399fbb3b 1 parent 6eb9f69
@lucianot authored
View
18 Gemfile
@@ -1,20 +1,18 @@
source 'http://rubygems.org'
-gem 'rails', '3.0.7'
-gem 'sqlite3', '1.3.3'
-gem 'devise', '1.3.4'
+gem 'rails', ">=3.1.0"
+gem 'sqlite3', '>=1.3.4'
+gem 'devise', '>=1.4.4'
group :development, :test do
- gem 'rspec-rails', '2.5.0'
+ gem 'rspec-rails', '>=2.6.1'
gem 'ruby-debug19', :require => 'ruby-debug'
- gem 'foreigner'
+ gem 'foreigner', '>=1.1.1'
end
group :test do
- gem 'capybara', :git => 'https://github.com/jnicklas/capybara.git',
- :ref => 'e73e77690ba4'
- gem 'factory_girl', '1.3.3'
- gem 'valid_attribute'
+ gem 'capybara', '>=1.1.0' # :git => 'https://github.com/jnicklas/capybara.git', :ref => 'e73e77690ba4'
+ gem 'factory_girl', '>=2.1.0'
+ gem 'valid_attribute', '>=1.1.0'
gem 'spork', '0.9.0.rc5'
- gem 'valid_attribute'
end
View
208 Gemfile.lock
@@ -1,110 +1,113 @@
-GIT
- remote: https://github.com/jnicklas/capybara.git
- revision: e73e77690ba41ab81a4254fb3239f1d3bd0c049d
- ref: e73e77690ba4
+GEM
+ remote: http://rubygems.org/
specs:
- capybara (0.4.1.1)
+ actionmailer (3.1.0)
+ actionpack (= 3.1.0)
+ mail (~> 2.3.0)
+ actionpack (3.1.0)
+ activemodel (= 3.1.0)
+ activesupport (= 3.1.0)
+ builder (~> 3.0.0)
+ erubis (~> 2.7.0)
+ i18n (~> 0.6)
+ rack (~> 1.3.2)
+ rack-cache (~> 1.0.3)
+ rack-mount (~> 0.8.2)
+ rack-test (~> 0.6.1)
+ sprockets (~> 2.0.0)
+ activemodel (3.1.0)
+ activesupport (= 3.1.0)
+ bcrypt-ruby (~> 3.0.0)
+ builder (~> 3.0.0)
+ i18n (~> 0.6)
+ activerecord (3.1.0)
+ activemodel (= 3.1.0)
+ activesupport (= 3.1.0)
+ arel (~> 2.2.1)
+ tzinfo (~> 0.3.29)
+ activeresource (3.1.0)
+ activemodel (= 3.1.0)
+ activesupport (= 3.1.0)
+ activesupport (3.1.0)
+ multi_json (~> 1.0)
+ archive-tar-minitar (0.5.2)
+ arel (2.2.1)
+ bcrypt-ruby (3.0.0)
+ builder (3.0.0)
+ capybara (1.1.0)
mime-types (>= 1.16)
nokogiri (>= 1.3.3)
rack (>= 1.0.0)
rack-test (>= 0.5.4)
- selenium-webdriver (>= 0.0.27)
- xpath (~> 0.1.3)
-
-GEM
- remote: http://rubygems.org/
- specs:
- abstract (1.0.0)
- actionmailer (3.0.7)
- actionpack (= 3.0.7)
- mail (~> 2.2.15)
- actionpack (3.0.7)
- activemodel (= 3.0.7)
- activesupport (= 3.0.7)
- builder (~> 2.1.2)
- erubis (~> 2.6.6)
- i18n (~> 0.5.0)
- rack (~> 1.2.1)
- rack-mount (~> 0.6.14)
- rack-test (~> 0.5.7)
- tzinfo (~> 0.3.23)
- activemodel (3.0.7)
- activesupport (= 3.0.7)
- builder (~> 2.1.2)
- i18n (~> 0.5.0)
- activerecord (3.0.7)
- activemodel (= 3.0.7)
- activesupport (= 3.0.7)
- arel (~> 2.0.2)
- tzinfo (~> 0.3.23)
- activeresource (3.0.7)
- activemodel (= 3.0.7)
- activesupport (= 3.0.7)
- activesupport (3.0.7)
- archive-tar-minitar (0.5.2)
- arel (2.0.9)
- bcrypt-ruby (2.1.4)
- builder (2.1.2)
- childprocess (0.1.8)
+ selenium-webdriver (~> 2.0)
+ xpath (~> 0.1.4)
+ childprocess (0.2.2)
ffi (~> 1.0.6)
columnize (0.3.2)
- devise (1.3.4)
- bcrypt-ruby (~> 2.1.2)
+ devise (1.4.4)
+ bcrypt-ruby (~> 3.0)
orm_adapter (~> 0.0.3)
warden (~> 1.0.3)
- diff-lcs (1.1.2)
- erubis (2.6.6)
- abstract (>= 1.0.0)
- factory_girl (1.3.3)
- ffi (1.0.7)
- rake (>= 0.8.7)
- foreigner (1.0.2)
+ diff-lcs (1.1.3)
+ erubis (2.7.0)
+ factory_girl (2.1.0)
+ ffi (1.0.9)
+ foreigner (1.1.1)
activerecord (>= 3.0.0)
- i18n (0.5.0)
- json_pure (1.5.1)
+ hike (1.2.1)
+ i18n (0.6.0)
+ json_pure (1.5.4)
+ spruz (~> 0.2.8)
linecache19 (0.5.12)
ruby_core_source (>= 0.1.4)
- mail (2.2.19)
- activesupport (>= 2.3.6)
+ mail (2.3.0)
i18n (>= 0.4.0)
mime-types (~> 1.16)
treetop (~> 1.4.8)
mime-types (1.16)
- nokogiri (1.4.4)
- orm_adapter (0.0.4)
- polyglot (0.3.1)
- rack (1.2.2)
- rack-mount (0.6.14)
+ multi_json (1.0.3)
+ nokogiri (1.5.0)
+ orm_adapter (0.0.5)
+ polyglot (0.3.2)
+ rack (1.3.2)
+ rack-cache (1.0.3)
+ rack (>= 0.4)
+ rack-mount (0.8.3)
rack (>= 1.0.0)
- rack-test (0.5.7)
+ rack-ssl (1.3.2)
+ rack
+ rack-test (0.6.1)
rack (>= 1.0)
- rails (3.0.7)
- actionmailer (= 3.0.7)
- actionpack (= 3.0.7)
- activerecord (= 3.0.7)
- activeresource (= 3.0.7)
- activesupport (= 3.0.7)
+ rails (3.1.0)
+ actionmailer (= 3.1.0)
+ actionpack (= 3.1.0)
+ activerecord (= 3.1.0)
+ activeresource (= 3.1.0)
+ activesupport (= 3.1.0)
bundler (~> 1.0)
- railties (= 3.0.7)
- railties (3.0.7)
- actionpack (= 3.0.7)
- activesupport (= 3.0.7)
+ railties (= 3.1.0)
+ railties (3.1.0)
+ actionpack (= 3.1.0)
+ activesupport (= 3.1.0)
+ rack-ssl (~> 1.3.2)
rake (>= 0.8.7)
- thor (~> 0.14.4)
- rake (0.8.7)
- rspec (2.5.0)
- rspec-core (~> 2.5.0)
- rspec-expectations (~> 2.5.0)
- rspec-mocks (~> 2.5.0)
- rspec-core (2.5.1)
- rspec-expectations (2.5.0)
+ rdoc (~> 3.4)
+ thor (~> 0.14.6)
+ rake (0.9.2)
+ rdoc (3.9.4)
+ rspec (2.6.0)
+ rspec-core (~> 2.6.0)
+ rspec-expectations (~> 2.6.0)
+ rspec-mocks (~> 2.6.0)
+ rspec-core (2.6.4)
+ rspec-expectations (2.6.0)
diff-lcs (~> 1.1.2)
- rspec-mocks (2.5.0)
- rspec-rails (2.5.0)
+ rspec-mocks (2.6.0)
+ rspec-rails (2.6.1)
actionpack (~> 3.0)
activesupport (~> 3.0)
railties (~> 3.0)
- rspec (~> 2.5.0)
+ rspec (~> 2.6.0)
ruby-debug-base19 (0.11.25)
columnize (>= 0.3.1)
linecache19 (>= 0.5.11)
@@ -116,20 +119,27 @@ GEM
ruby_core_source (0.1.5)
archive-tar-minitar (>= 0.5.2)
rubyzip (0.9.4)
- selenium-webdriver (0.2.0)
- childprocess (>= 0.1.7)
+ selenium-webdriver (2.5.0)
+ childprocess (>= 0.2.1)
ffi (>= 1.0.7)
json_pure
rubyzip
spork (0.9.0.rc5)
- sqlite3 (1.3.3)
+ sprockets (2.0.0)
+ hike (~> 1.2)
+ rack (~> 1.0)
+ tilt (!= 1.3.0, ~> 1.1)
+ spruz (0.2.13)
+ sqlite3 (1.3.4)
thor (0.14.6)
- treetop (1.4.9)
+ tilt (1.3.3)
+ treetop (1.4.10)
+ polyglot
polyglot (>= 0.3.1)
- tzinfo (0.3.27)
- valid_attribute (0.0.3)
- warden (1.0.3)
- rack (>= 1.0.0)
+ tzinfo (0.3.29)
+ valid_attribute (1.1.0)
+ warden (1.0.5)
+ rack (>= 1.0)
xpath (0.1.4)
nokogiri (~> 1.3)
@@ -137,13 +147,13 @@ PLATFORMS
ruby
DEPENDENCIES
- capybara!
- devise (= 1.3.4)
- factory_girl (= 1.3.3)
- foreigner
- rails (= 3.0.7)
- rspec-rails (= 2.5.0)
+ capybara (>= 1.1.0)
+ devise (>= 1.4.4)
+ factory_girl (>= 2.1.0)
+ foreigner (>= 1.1.1)
+ rails (>= 3.1.0)
+ rspec-rails (>= 2.6.1)
ruby-debug19
spork (= 0.9.0.rc5)
- sqlite3 (= 1.3.3)
- valid_attribute
+ sqlite3 (>= 1.3.4)
+ valid_attribute (>= 1.1.0)
View
7 app/assets/application.css
@@ -0,0 +1,7 @@
+/*
+ * This is a manifest file that'll automatically include all the stylesheets available in this directory
+ * and any sub-directories. You're free to add application-wide styles to this file and they'll appear at
+ * the top of the compiled file, but it's generally better to create a new file per style scope.
+ *= require_self
+ *= require_tree .
+*/
View
9 app/assets/application.js
@@ -0,0 +1,9 @@
+// This is a manifest file that'll be compiled into including all the files listed below.
+// Add new JavaScript/Coffee code in separate files in this directory and they'll automatically
+// be included in the compiled file accessible from http://example.com/assets/application.js
+// It's not advisable to add code directly here, but if you do, it'll appear at the bottom of the
+// the compiled file.
+//
+//= require jquery
+//= require jquery_ujs
+//= require_tree .
View
0  public/images/arrowdown.png → app/assets/images/arrowdown.png
File renamed without changes
View
0  public/images/arrowup.png → app/assets/images/arrowup.png
File renamed without changes
View
0  public/images/rails.png → app/assets/images/rails.png
File renamed without changes
View
0  public/javascripts/application.js → app/assets/javascripts/application.js
File renamed without changes
View
0  public/javascripts/controls.js → app/assets/javascripts/controls.js
File renamed without changes
View
0  public/javascripts/dragdrop.js → app/assets/javascripts/dragdrop.js
File renamed without changes
View
0  public/javascripts/effects.js → app/assets/javascripts/effects.js
File renamed without changes
View
0  public/javascripts/prototype.js → app/assets/javascripts/prototype.js
File renamed without changes
View
0  public/javascripts/rails.js → app/assets/javascripts/rails.js
File renamed without changes
View
0  public/stylesheets/.gitkeep → app/assets/stylesheets/.gitkeep
File renamed without changes
View
0  public/stylesheets/scaffold.css → app/assets/stylesheets/scaffold.css
File renamed without changes
View
2  app/models/link.rb
@@ -41,7 +41,7 @@ def vote_by(user)
def clean_url
#use try instead for nil?
unless self.url.nil?
- parsed_url = URI.parse(self.url).host.sub(/\Awww\./, '')
+ parsed_url = URI.parse(self.url).host.sub(/\Awww\./, '')
else
nil
end
View
4 app/views/layouts/application.html.erb
@@ -2,8 +2,8 @@
<html>
<head>
<title>Reddit clone</title>
- <%= stylesheet_link_tag :all %>
- <%= javascript_include_tag :defaults %>
+ <%= stylesheet_link_tag "application" %>
+ <%= javascript_include_tag "application" %>
<%= csrf_meta_tag %>
</head>
<body>
View
3  config/application.rb
@@ -6,6 +6,9 @@
# you've limited to :test, :development, or :production.
Bundler.require(:default, Rails.env) if defined?(Bundler)
+# Enable the asset pipeline
+config.assets.enabled = true
+
module Redditclone
class Application < Rails::Application
# Settings in config/environments/* take precedence over those specified here.
View
2  config/environments/development.rb
@@ -11,7 +11,7 @@
# Show full error reports and disable caching
config.consider_all_requests_local = true
- config.action_view.debug_rjs = true
+ # config.action_view.debug_rjs = true
config.action_controller.perform_caching = false
# Don't care if the mailer can't send
View
4 config/environments/production.rb
@@ -46,4 +46,8 @@
# Send deprecation notices to registered listeners
config.active_support.deprecation = :notify
+
+ # Compress both stylesheets and JavaScripts
+ config.assets.js_compressor = :uglifier
+ config.assets.css_compressor = :scss
end
Please sign in to comment.
Something went wrong with that request. Please try again.