I have created a rails project in Intellij IDEA, but when I try to run the project, I get the error: "No rails found in SDK". When I create a project that I just can not choose the version of rails from the list, but the rails have on my system, and if I write "rails -v" in the terminal, I got an answer: Rails 4.2.1. What am I doing wrong? Thanks
Open Preferences -> Languages & Frameworks -> Ruby SDK & Gems and choose required ruby version from list.
Or open Run/Debug Configuration editor and select Ruby SDK from Ruby SDK (Use other SDK) list.
Related
Searching on the jetbrains website, I came up with this: https://www.jetbrains.com/ruby/help/configuring-ruby-sdk.html. However, I don't have the Ruby SDK pane. I have set the project to have the Project SDK for the version of Ruby installed, the Modules->Dependencies has the version of Ruby selected, but each time the project loads, it prompts me to set the framework to JRuby. It's not a JRuby project. Granted, I don't have RubyMine, but I thought that that was the purpose of Ultimate, to be an all-in-one.
Maybe a late response, but here's answer anyway. I stumbled upon the same issue while evaluating the Ultimate version.
To fix the "JRuby on Rails framework detected" issue, just create a new project "from existing sources". Follow the steps in the wizard and "Ruby on Rails" framework will be detected correctly - no more JRuby...
Hope it helps!
How to configure Ruby interpreter in RubyMine ? I have not understood what the website of Rubymine is trying to say. please help me
thanks!i have a project name "Untitled" and its class name is naqash.rb , but when i try to run ! it says an error , no SDK specified. so how i can solve that problem
Well since you are on windows 7 you need to install ruby so follow this http://rubyinstaller.org/downloads/
Then go back to preferences and see if your sdks is there.
I am trying to run RoR on Netbeans 7. I installed everything as given in the documentation. I have Ruby 1.9.2 and Rails 3.0.9 installed on my PC.
Also I have the plugins installed with the Netbeans 7.0
But when I try to create a new project, the progress hangs on 25% and Netbeans stops responding. I have to use task Manager to close the IDE. What is wrong in the scenario? Thank you.
Well help on this will be limited because netbeans no longer supports Rails:
http://netbeans.org/community/news/show/1507.html
Good news though, you don't need netbeans to create a rails project. Just open up your terminal and run:
rails new APP_NAME
Each time I have seen this happen Netbeans is happily awaiting input. When you create the project in Netbeans it executes rails new APP underneath and if that process asks a question, then Netbeans will hang. Check the Netbeans output window (if it's open). You can verify this by creating the rails app on the command line. Once you do that, open the directory with Netbeans and it should recognize the project as a Rails project.
Does anybody know how I can run alternative Rails generators in Netbeans 6.7? I have installed nifty-scaffold and want to want to find how I can run the following command from the IDE:
script/generate nifty_scaffold etc ....
I have installed the nifty-scaffold gem, but it does not appear in the drop-down list when I select 'Generate' for my project.
(I am running NetBeans on Windows)
It would be very easy to add new generator extensions in netbeans. Netbeans doesn't do it
automatically, you need to do it manually. I am using NetBeans ver 6.8 and installed nifty generators successfully in netbeans by following procedure:
1. Download gems file of ryanb's nifty generator freely available.
2. install in netbeans from tools->rubygems-> install Local
3. go to the directory C:\Program Files\NetBeans 6.8\ruby2\jruby-1.4.0\lib\ruby\gems\1.8\gems\rails-2.3.5\lib\rails_generator\generators\components. It shows all the generators available in netbeans.
4. go to the directory C:\Program Files\NetBeans 6.8\ruby2\jruby-1.4.0\lib\ruby\gems\1.8\gems\nifty-generators-0.3.0\rails_generators. It shows the nifty generators which you have just now installed.
5. Copy all nifty generators to components directory shown in step 3.
6. right click on project and click generate and you will find the udpated list of all new generators
By
Vikas Maan
I assume that when you say you installed the gem, you did so through the Generate...->Install Generators button?
However, it does seem to be a defect. I've tested it too on Windows & Netbeans 6.7 and reproduced your problem - Netbeans can't find the generators even though script/generate can. It's probably worth shooting an email off to the Ruby Netbeans mailing list and/or filing a bug here.
You can create a folder named "generators" in your "lib" folder and put any generator folders in it and it should be working.
Or put that "generators" folder in your "vendor" folder.
Link to nifty-generator GEM(version 0.3):
http://rubyforge.org/frs/?group_id=6986
I wasn't able to install local gem from github, but above link works.
It works with Rails 2.
Where can I find project templates for Ruby on Rails to use within projects?
I am using Xcode version 3.2.2.
From what I understand, Apple stopped shipping all project templates with xcode and made them available as optional downloads, yet I cannot find the templates for Ruby on Rails anywhere.
Regards
Mick
Because the "template" of a fresh rails app can change from version to version, you should use the rails new myapp generator command at the Terminal, and the open the result in XCode organizer.
More here: http://developer.apple.com/tools/developonrailsleopard.html