Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Unable to run .rb file with SCITE editor

14 views
Skip to first unread message

Sanjeev Oza

unread,
Feb 17, 2010, 2:35:02 AM2/17/10
to
I have re-installed Ruby on my pc and run some rb files but these files
are not giving any output rather gives error 'The system cannot find the
file specified.' The same files were working before re-installation but
are not working later. Please help...
--
Posted via http://www.ruby-forum.com/.

Roger Pack

unread,
Feb 17, 2010, 8:17:45 AM2/17/10
to
Sanjeev Oza wrote:
> I have re-installed Ruby on my pc and run some rb files but these files
> are not giving any output rather gives error 'The system cannot find the
> file specified.' The same files were working before re-installation but
> are not working later. Please help...

try reinstalling, and/or right click on them -> "open wish", choose
SciTe, check the "always open with" checkbox.
GL.
-r

Sanjeev Oza

unread,
Feb 17, 2010, 9:03:27 AM2/17/10
to
Thanks Roger for your comments,

I believe you are under impression that I am not able to open file with
SCITE editor but the actual problem is if I am saving the .rb file and
trying to run the code by 'F5' button then it gives me error 'the system

cannot find the file specified.'

--
Posted via http://www.ruby-forum.com/.

Chris Hulan

unread,
Feb 17, 2010, 9:20:39 AM2/17/10
to

SOunds like the new install didn't add your ruby bin dir to the path

I think you can also edit the ruby properties file (in SciTe) to give
the full path to ruby.exe

Marvin Gülker

unread,
Feb 17, 2010, 9:27:27 AM2/17/10
to
Sanjeev Oza wrote:
> Thanks Roger for your comments,
>
> I believe you are under impression that I am not able to open file with
> SCITE editor but the actual problem is if I am saving the .rb file and
> trying to run the code by 'F5' button then it gives me error 'the system
> cannot find the file specified.'

I suppose your script directory path or the script name itself contains
whitespace. SciTE can cope with that, just open the Ruby options file
(you'll have to be root on Linux systems) via SciTEs Options -> Edit
Properties -> Open Ruby properties menu and change the entry
command.go.*.rb=ruby $(FileNameExt)
to
command.go.*.rb=ruby "$(FileNameExt)"
Note the quotes.
There are two entries, one for the GTK platform and one for Windows,
choose that one apropriate for you.

Marvin

Sanjeev Oza

unread,
Feb 17, 2010, 9:44:00 AM2/17/10
to
I updated Ruby properties file in "C:\ruby\scite" as per your above
instruction but the error message not changed yet.

Marvin Gülker

unread,
Feb 17, 2010, 10:14:38 AM2/17/10
to
Sanjeev Oza wrote:
> I updated Ruby properties file in "C:\ruby\scite" as per your above
> instruction but the error message not changed yet.

You've to restart SciTE afterwards.
What about pathnames without spaces? Try placing a script directly as
C:\myscript.rb and then run it from inside SciTE. Does this work?

> SOunds like the new install didn't add your ruby bin dir to the path

Yeah, that's also possible. Type "ruby -v" in cmd and post the output.

Marvin

Roger Pack

unread,
Feb 18, 2010, 12:21:13 AM2/18/10
to
Sanjeev Oza wrote:
> Marvin,
>
> I have restarted SciTE afterwards but it doesn't work.
> I have tried to run the ruby file from root directory by using SciTE but
> it gives me same output and if i am typing "ruby -v" in cmd then it
> gives me error says 'ruby'is not recognised as an internal or external
> command...

ruby.exe is most likely not in your path then. Reinstall ruby and
reboot :)
-r

Sanjeev Oza

unread,
Feb 19, 2010, 7:28:11 AM2/19/10
to
Thanks Roger,

For your kind help as the issue is resolved after successfull
re-installment of Ruby.

0 new messages