Tagged Questions
52
votes
6answers
23k views
Rails - Could not find a JavaScript runtime?
I created a new Rails project using rails 3.1.0.rc4 on my local machine but when I try to start the server I get:
Could not find a JavaScript runtime. See here for a list of available runtimes. ...
69
votes
4answers
12k views
Rails 3.1: Engine vs. Mountable App
Can someone help me understand the differences between a Rails Engine and a Mountable app? In Rails 3.1, you can create either one with the "rails new plugin ___" command.
rails plugin new forum ...
31
votes
6answers
4k views
How do I write a Rails 3.1 engine controller test in rspec?
I have written a Rails 3.1 engine with the namespace Posts. Hence, my controllers are found in app/controllers/posts/, my models in app/models/posts, etc. I can test the models just fine. The spec for ...
33
votes
1answer
17k views
Rails 3.2, FATAL: Peer authentication failed for user (PG::Error)
I am running my development on Ubuntu 11.10, and RubyMine
Here is my development settings for the database.yml: which RubyMine created for me
development:
adapter: postgresql
encoding: unicode
...
22
votes
4answers
4k views
blueprint css rails 3.1 help
My blueprint css works on my local machine, but when I push to heroku I get an error.
I have blueprint stored in my app/assets/stylesheets folder and here are the stylesheet tags I'm using:
<%= ...
19
votes
6answers
13k views
rails - “WARNING: Can't verify CSRF token authenticity” for json devise requests
do you know how it is possible to correctly retrieve the CSRF token to pass with a JSON request?
I know that for security reason now Rails is enforcing CSRF check on all the request type (including ...
17
votes
8answers
8k views
rails 3.1 asset pipeline css caching in development
I'm a bit confused as it seems like the application.css is including itself twice, once when it lists the resources from the manifest and then a cache of that. So when I delete an individual file it ...
11
votes
4answers
4k views
Don't know how to build task 'assets:precompile'
I'm getting that error on my production server, and can't figure out why. It happens when running this command:
bundle exec rake assets:precompile RAILS_ENV=production
I'm using Rails 3.1.0.rc6
3
votes
1answer
610 views
rails 3 activerecord order - what is the proper sql injection work around?
let us say I have a list page of users and you can sort by the different columns, when clicking 'email' it will pass sort_by=email sort_direction=asc or desc
sort_by = "email" # really ...
56
votes
9answers
23k views
28
votes
4answers
17k views
Rails 3.1 serving images from vendor/assets/images
I am trying to put some external images (used by a jQuery plugin) to vendor/assets/images in my Rails 3.1 app. Problem is that when I try something like:
<%= image_tag ...
24
votes
4answers
5k views
What is the value of Compass for Rails 3.1?
I'm trying to decide if I should include Compass when starting a new Rails 3.1 project. I haven't used Compass before.
Rails 3.1 now supports SCSS directly. The Rails 3.1 asset pipeline (via ...
11
votes
6answers
9k views
Rails 3.1 issue with javascript_include_tag in application.html.erb
I've created a clean and simple Rails 3.1 application called demo1. It contains two controllers - hello and goodbye. I get the following error when I try to load http://localhost:3000/say/hello:
...
5
votes
7answers
5k views
rvm install: ruby installation error
I want to install ruby on my Linux Mint 12.
I am following this tutorial and this one.
when I run rvm install 1.9.3 I see this error:
Installing Ruby from source to: ...
8
votes
4answers
2k views
Rails v2.3 : Difference between session and cookies
I am learning Rails by reading the online guide(for Rails v2.3). The guide is great, however, there is a confusion for me, that's:
there is a chapter explains the Session of Rails and another chapter ...