# 3rdrail run rake task error: no Ruby script found in input (LoadError) (Windows)

**URL:** <https://www.ruby-forum.com/t/3rdrail-run-rake-task-error-no-ruby-script-found-in-input-loaderror-windows/124689>\
**Category:** Rails\
**Created:** [January 1, 2008, 4:49am UTC](https://www.ruby-forum.com/t/3rdrail-run-rake-task-error-no-ruby-script-found-in-input-loaderror-windows/124689 "2008-01-01T04:49:57Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Issac](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/cab0a1/32.png) [@Issac](https://www.ruby-forum.com/u/Issac)\
**Post date:** [January 1, 2008, 4:49am UTC](https://www.ruby-forum.com/t/3rdrail-run-rake-task-error-no-ruby-script-found-in-input-loaderror-windows/124689/1 "2008-01-01T04:49:57Z")

</div>

Hi, dudes  
I got a question here. When I run “rake db:migrate” in 3rdrail, it  
throws an error: D:\ruby\bin\ruby.exe: no Ruby script found in input  
(LoadError). I have set the ruby interpreter paths, And can’t find the  
solution on Google. Any good ideas?

Issac

---

<div class="post-metadata">

**Author:** ![Issac](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/cab0a1/32.png) [@Issac](https://www.ruby-forum.com/u/Issac)\
**Post date:** [January 2, 2008, 11:14am UTC](https://www.ruby-forum.com/t/3rdrail-run-rake-task-error-no-ruby-script-found-in-input-loaderror-windows/124689/2 "2008-01-02T11:14:08Z")

</div>

Issac wrote:

> Hi, dudes  
> I got a question here. When I run “rake db:migrate” in 3rdrail, it  
> throws an error: D:\ruby\bin\ruby.exe: no Ruby script found in input  
> (LoadError). I have set the ruby interpreter paths, And can’t find the  
> solution on Google. Any good ideas?
> 
> Issac

Got the same problem, rails build is v20071130\_1710 and I’m using  
Instant Rails 2.0. This error occured after updating both to the  
currently newest version.

A workaround is calling “rake db:migrate” from the ruby console window  
from instant rails, i.e. not 3rdRails, so that the environment is set.

---

<div class="post-metadata">

**Author:** ![Issac](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/cab0a1/32.png) [@Issac](https://www.ruby-forum.com/u/Issac)\
**Post date:** [February 7, 2008, 11:25pm UTC](https://www.ruby-forum.com/t/3rdrail-run-rake-task-error-no-ruby-script-found-in-input-loaderror-windows/124689/3 "2008-02-07T23:25:18Z")

</div>

As far as I can tell, this is caused by the …/bin/rake file not having  
a  
ï¿½ï¿½#! line.

So you should be able to add one, and continue as normal.

---

<div class="post-metadata">

**Author:** ![Issac](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/i/cab0a1/32.png) [@Issac](https://www.ruby-forum.com/u/Issac)\
**Post date:** [February 24, 2008, 2:25pm UTC](https://www.ruby-forum.com/t/3rdrail-run-rake-task-error-no-ruby-script-found-in-input-loaderror-windows/124689/4 "2008-02-24T14:25:24Z")

</div>

I get this using 3rdRail too, with this in …/bin/rake:

#!c:/Program Files/Ruby/bin/ruby.exe

# 

# This file was generated by RubyGems.

# 

# The application ‘rake’ is installed as part of a gem, and

# this file is here to facilitate running it.

# 

require ‘rubygems’

version = “\>= 0”

if ARGV.first =~ /^_(.\*)_$/ and Gem::Version.correct? $1 then  
version = $1  
ARGV.shift  
end

gem ‘rake’, version  
load ‘rake’

Just to be clear, by this I mean:

c:\Program Files\Ruby\bin\ruby.exe: no Ruby script found in input  
(LoadError)

when running the migration in 3rdRail.  
Running the same migration (i.e. rake db:migrate VERSION=001) from the  
command-line works fine though.
