I just installed aptana, and i have the repository for the rails project.. So i open a new project and point it to my repository.. and it opens... But i can't do any rake tasks. Under rake tab, it says that "no rake tasts found. Likely cause is no Rakefile for the project"
But i can see the Rakefile in the project.. Can anyone help?
The problem is you have to change the Installed Interpreter path in aptana studio , by default the aptana studio takes it own version of the interpreter ie org.jruby . Make sure to change the path to your locally installed ruby environment .
In order to change it go to Windows->Preference->Ruby->Installed Interpreters
If you are working in windows Add a new environment provide
RubyVM home directory = c:\ruby
If you are working in ubuntu or any other linux platform provide
RubyVM home directory = /usr/bin
This makes all the gems ,rake to available to your aptana studio . still if doesnot work
second option would be, provide the rake path where you have installed in aptana .
In order to change it go to Windows->Preference->Ruby->Rake
provide the rake path = (your-installed-rake path )
Good luck !
I'm a bit late but I've encountered a similar issue and finally found out that there was no target in Rakefile, that's why this message is displayed. Just add one and this error message will go away.
Related
I installed ruby 1.9.3 w/ rubyinstaller-1.9.3-p194.exe, and then installed RubyMine right after, as per directions:
http://www.jetbrains.com/ruby/quickstart/index.html
and
http://rubyinstaller.org/
I have git hub for windows already installed which I don't know if that could cause the problem.
I have also installed ruby and rails several times but I looked through the PATH environment variable for any no longer existing installations and removed them (after having already had this error) which didn't help.
Here are the settings I select in RubyMine.
The error message:
"C:\Ruby193\bin\ruby.exe -e $stdout.sync=true;$stderr.sync=true;load($0=ARGV.shift) C:\Ruby193\bin/rails 3.2.6 new "D:/Program Files (x86)/Git/Rails App/asfasf" --skip-test-unit --javascript=jquery --skip --database=postgresql
exist D:/Program Files (x86)/Git/Rails App/asfasf
Could not find "README" in any of your source paths. Your current source paths are:
C:/Ruby193/lib/ruby/gems/1.9.1/gems/railties-3.2.6/lib/rails/generators/rails/app/templates
Process finished with exit code 1"
I apologize if I come across as angry / frustrated (I edited this several times to remove it) as I have been trying to get RubyMine to work on Windows 7 or Ubuntu 12.04 and neither have been successful.
Any advice would be greatly appreciated!
I continued searching through the web for information and remembered somewhere installing rails on windows previously that for some reasons files couldn't have spaces in them.
Long story short: make sure your path doesn't have spaces in the name because it breaks rubymine or rails or something along the way.
Changing my project folder to a destination with no spaces solved the problem.
When I try to create new rails project Aptana gves :
"Can't initialize a new Rails application within the directory of another, please change to a non-Rails direct
ory first."
error and also when I type ls it does not give current project folder content it gives something else. In addition when I open the Webrick for the ptoject it does not show my project instead it gives rails initial front page.
Do you see the error please help
The problem is not in Aptana Studio. I got a similar message after my manipulations with DevKit_mingw assembly, although before Aptana it works fine. In my case uninstalling Ruby, devKit and Aptana helped. Then I just install RailsInstaller + AptanaStudio. I hope my experience will help someone else.
If you're using Aptana in windows, and your workspace is C:\user\My Documents\Aptana Studio 3 Workspace. The problem is that the folder of your workspace is read-only. You should change the privileges in this folder for you can write into the folder of yours project.
I'm just starting out with rails and I'm practicing the basic ruby commands, one of which is the rails new myproject command.
My projects are under the Aptana workspace directory where I've used the command line and Aptana both to create projects there. After a few creations and rails s commands and deletions, I've started getting this error message when I try to generate a new rails project:
"Can't initialize a new Rails application within the directory of
another, please Type 'rails' for help."
This doesn't just happen when I create a new project (rails new myproject) under the Aptana workspace directory, but also when I use the command rails new . directly inside the workspace directory. Can someone explain to me what I need to do to flush rails so it knows I don't have a project there anymore? What did I do to make this happen?
I don't remember what rails looking for. The quickest way to solve this issue is to completely empty the affected directory.
Most likely there are some hidden files or directories which prevents rails from creating a new project. Look at that with ls -a probably there is a .bundle folder inside that dir.
I got same problem since I failed to create rails project. I tried to remove Aptana plug-in and Eclipe that include ./eclipse, ./metadata but not sloved the problem until I removed Ruby and Devkit and reinstall them again.
So, I think the root cause may in Devkit or Ruby. The problem work out after I reinstall Ruby(rubyinstaller-2.2.3-x64.exe) and DevKit(DevKit-mingw64-64-4.7.2-20130224-1432-sfx.exe).
If you are under Windows, you must install Aptana Studio as administrator or it will not work properly. Uninstall and install it as administrator and the terminal folder will be set correctly
I just installed ruby on rails on my new computer ( I was using instantrails before) and I'm trying to get everything setup.
Im running Windows 7. So I followed the instructions from this tutorial.
http://blogupstairs.com/ruby-on-rails/installing-ruby-on-rails-on-windows-7/
The problem i'm guessing is step 3
"Add the newly installed bin directory to your path in your windows system : Open windows explorer-> right click the icon computer-> choose Properties -> in the contol panel Home, Click Advanced system settings and then click Envitonment Variables button->in the system variables click new and add new system variables like this : Variable name : RUBY_HOME , Variable Value : C:\Ruby, after that add it in to the path and add the bin after a semicolon to the “Path” variable like this : C:\Program Files\Common Files\Adobe\AGL;%JAVA_HOME%\bin;%ANDROID_HOME%\tools;%RUBY_HOME%\bin"
I set created the system variables but when I try to run script/generate in the main directory of my app I get the error
"Ruby: no such file or directory --script/generate"
I checked the apps directory and the script folder is in there. How can I run the "ruby script/generate" commands from the control panel?
I was guessing it was something with the path but I dont know any ways to check to find out whats going wrong.
Are you using Rails 3.0+? In this version of rails and up, the script/* folder has been deprecated in favor of rails generate, rails server, etc. See here.
In 99.99999% of all cases, if a computer tells you that it cannot find a file at a specific location, it is because that file is not at that specific location.
So, is there actually a file named generate in a directory named script in the current directory?
I have recently installed RoR on my "clean" Win7 as well.
What IDE are you using?
I suggest trying JRuby with NetBeans/RubyMine:
JRuby installer does all the work (even adds the proper variables to your path in system environment settings...,
IDEs take care of gems, setting up servers etc.
As for the commands, as Nuclearsandwitch mentioned, there is no script/generate or script/server in Rails 3. Just make sure you in the directory with your Rails app and then try running rails server. It should work :-)
I am using Windows 7 and Ruby 1.8.7. I get the following error message when I start a new Rails project:
Problem Occured
'Replace project index file' has encountered a problem. Resource '/Foobar/public' does not exist. (where 'Foobar' is the name of my new project).
Any ideas?
Just found a workaround: Create the project but UNCHECK the part about generating a rails skeleton. Then open a console, navigate to the project's parent directory, and run rails <project name>. The skeleton will generate in the folder, and then you can refresh the project directory within Aptana/Eclipse.
When new project is created using radrails, RadRails execute the command rails beta -d sqlite3 which is older syntax and the new syntax is rails new beta -d sqlite3 So unless the Aptana Teams invokes new rails functionality the workaround would be to use the methods mentioned above.
Follow the same procedure as mentioned above....
But for me Rails didn't work.
rails new "project name" worked for me.
Thanks
I had this problem because my project had spaces in the name. Removed the spaces and it worked.
I've the same problem but in web projects and using a network directory. I create the project in local and then move it to network unity.
Try running your IDE as an administrator. Right click your IDE icon -> "Run as administrator".
Now your IDE will have the appropriate privileges to write files and folders.
Changing the interpreter that the IDE uses worked for me. Go to windows->preferences->ruby->installed interpreters then select the one that comes with your installation of Aptana Studio, mine's name is org.jruby_1.2.0.9... It worked like a charm for me. I hope that helped.