[wtr-general] Re: How to change a ruby file into an .exe file
It's your Ruby script whichever you wanted to load :) On Apr 3, 4:40 pm, neeraj girdhar er.neeraj...@gmail.com wrote: Hi, what is this '/something' in your code. Regards, Neeraj --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Watir General group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~--~~~~--~~--~--~---
[wtr-general] Re: How to change a ruby file into an .exe file
Hi, what is this '/something' in your code. Regards, Neeraj On Thu, Apr 2, 2009 at 6:46 AM, Wesley Chen cjq@gmail.com wrote: Hi, Jarmo, Thank you very much, it is really useful. Thanks. Wesley Chen. On Wed, Apr 1, 2009 at 3:34 PM, Jarmo Pertman jarm...@gmail.com wrote: require 'rubyscript2exe' require RUBYSCRIPT2EXE.exedir + '/something' --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Watir General group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~--~~~~--~~--~--~---
[wtr-general] Re: How to change a ruby file into an .exe file
Yes, I've noticed, but I had in mind that you have to use other technique when using Rubyscript2exe. Instead of writing require 'File.dirname(__FILE__) + '/something' use: require 'rubyscript2exe' require RUBYSCRIPT2EXE.exedir + '/something' OR this should also work: require 'rubyscript2exe' require 'something' Regards, Jarmo On Mar 19, 3:13 pm, wesley chen cjq@gmail.com wrote: Hi, Pertman, You have not watched my post carefully, my File.dirname(__FILE__) is in my script, it is not a parameter to run rubyscript2exe. But thank you all the same. Thanks. Wesley Chen. On Thu, Mar 19, 2009 at 8:06 PM, Jarmo Pertman jarm...@gmail.com wrote: I remember that you had to use rubyscript2exe variables instead of File.dirname. Please refer to here to find out which one works for you: http://www.erikveen.dds.nl/rubyscript2exe/#3.3.0 On Mar 18, 2:57 pm, wesley chen cjq@gmail.com wrote: A problem exists: I create two .rb file in the same directory first is test1.rb, with code: require 'watir' $ie=Watir::IE.new second is test2.rb, with code: *require File.join(Dir.pwd, 'test1.rb')* $ie.goto(www.baidu.com) puts OK $ie.text_field(:id,'kw').set(www.baidu.com) $ie.button(:id,'sb').click puts OK $ie.close When I go to the right file directory, run rubyscript2exe test2.rb I get test2.exe, it can be executed as expected. Problem is: When I change the *require File.join(Dir.pwd, 'test1.rb')* to *require File.dirname(__FILE__) +'/test1.rb'* # *require File.dirname(__FILE__) +'\\test1.rb'* I can *rubyscript2exe test2.rb* into *test2.exe* as expected. But when I execute test2.exe, I get error message: *No such file to load --***\app\test1.rb(LoadError) * In my project, I use require File.dirname(__FILE__) + '/../..' anywhere, so how can make it so that, the exe file can be executed? Any suggestion would be quite appreciated. Thanks. Wesley Chen. On Wed, Mar 18, 2009 at 8:22 PM, wesley chen cjq@gmail.com wrote: Two steps to make the .rb file to .exe file. 1. go to your command line, run gem install rubyscript2exe 2. Go to your main.rb file directory, run rubyscript2exe main.rb It will make the main.rb into main.exe Thanks. Wesley Chen. On Sat, Feb 28, 2009 at 12:50 AM, Jarmo Pertman jarm...@gmail.com wrote: Or use rubyscript2exe, which also supports Linux and OSX. You can read more about it from here http://www.erikveen.dds.nl/rubyscript2exe/ On Feb 20, 10:38 am, Wilson Xu xu.xiaodong.wil...@gmail.com wrote: refer tohttp://rubyforge.org/projects/exerb/project. Wilson --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Watir General group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~--~~~~--~~--~--~---
[wtr-general] Re: How to change a ruby file into an .exe file
Hi, Jarmo, Thank you very much, it is really useful. Thanks. Wesley Chen. On Wed, Apr 1, 2009 at 3:34 PM, Jarmo Pertman jarm...@gmail.com wrote: require 'rubyscript2exe' require RUBYSCRIPT2EXE.exedir + '/something' --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Watir General group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~--~~~~--~~--~--~---
[wtr-general] Re: How to change a ruby file into an .exe file
I remember that you had to use rubyscript2exe variables instead of File.dirname. Please refer to here to find out which one works for you: http://www.erikveen.dds.nl/rubyscript2exe/#3.3.0 On Mar 18, 2:57 pm, wesley chen cjq@gmail.com wrote: A problem exists: I create two .rb file in the same directory first is test1.rb, with code: require 'watir' $ie=Watir::IE.new second is test2.rb, with code: *require File.join(Dir.pwd, 'test1.rb')* $ie.goto(www.baidu.com) puts OK $ie.text_field(:id,'kw').set(www.baidu.com) $ie.button(:id,'sb').click puts OK $ie.close When I go to the right file directory, run rubyscript2exe test2.rb I get test2.exe, it can be executed as expected. Problem is: When I change the *require File.join(Dir.pwd, 'test1.rb')* to *require File.dirname(__FILE__) +'/test1.rb'* # *require File.dirname(__FILE__) +'\\test1.rb'* I can *rubyscript2exe test2.rb* into *test2.exe* as expected. But when I execute test2.exe, I get error message: *No such file to load --***\app\test1.rb(LoadError) * In my project, I use require File.dirname(__FILE__) + '/../..' anywhere, so how can make it so that, the exe file can be executed? Any suggestion would be quite appreciated. Thanks. Wesley Chen. On Wed, Mar 18, 2009 at 8:22 PM, wesley chen cjq@gmail.com wrote: Two steps to make the .rb file to .exe file. 1. go to your command line, run gem install rubyscript2exe 2. Go to your main.rb file directory, run rubyscript2exe main.rb It will make the main.rb into main.exe Thanks. Wesley Chen. On Sat, Feb 28, 2009 at 12:50 AM, Jarmo Pertman jarm...@gmail.com wrote: Or use rubyscript2exe, which also supports Linux and OSX. You can read more about it from here http://www.erikveen.dds.nl/rubyscript2exe/ On Feb 20, 10:38 am, Wilson Xu xu.xiaodong.wil...@gmail.com wrote: refer tohttp://rubyforge.org/projects/exerb/project. Wilson --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Watir General group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~--~~~~--~~--~--~---
[wtr-general] Re: How to change a ruby file into an .exe file
Two steps to make the .rb file to .exe file. 1. go to your command line, run gem install rubyscript2exe 2. Go to your main.rb file directory, run rubyscript2exe main.rb It will make the main.rb into main.exe Thanks. Wesley Chen. On Sat, Feb 28, 2009 at 12:50 AM, Jarmo Pertman jarm...@gmail.com wrote: Or use rubyscript2exe, which also supports Linux and OSX. You can read more about it from here http://www.erikveen.dds.nl/rubyscript2exe/ On Feb 20, 10:38 am, Wilson Xu xu.xiaodong.wil...@gmail.com wrote: refer tohttp://rubyforge.org/projects/exerb/project. Wilson --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Watir General group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~--~~~~--~~--~--~---
[wtr-general] Re: How to change a ruby file into an .exe file
A problem exists: I create two .rb file in the same directory first is test1.rb, with code: require 'watir' $ie=Watir::IE.new second is test2.rb, with code: *require File.join(Dir.pwd, 'test1.rb')* $ie.goto(www.baidu.com) puts OK $ie.text_field(:id,'kw').set(www.baidu.com) $ie.button(:id,'sb').click puts OK $ie.close When I go to the right file directory, run rubyscript2exe test2.rb I get test2.exe, it can be executed as expected. Problem is: When I change the *require File.join(Dir.pwd, 'test1.rb')* to *require File.dirname(__FILE__) +'/test1.rb'* # *require File.dirname(__FILE__) +'\\test1.rb'* I can *rubyscript2exe test2.rb* into *test2.exe* as expected. But when I execute test2.exe, I get error message: *No such file to load --***\app\test1.rb(LoadError) * In my project, I use require File.dirname(__FILE__) + '/../..' anywhere, so how can make it so that, the exe file can be executed? Any suggestion would be quite appreciated. Thanks. Wesley Chen. On Wed, Mar 18, 2009 at 8:22 PM, wesley chen cjq@gmail.com wrote: Two steps to make the .rb file to .exe file. 1. go to your command line, run gem install rubyscript2exe 2. Go to your main.rb file directory, run rubyscript2exe main.rb It will make the main.rb into main.exe Thanks. Wesley Chen. On Sat, Feb 28, 2009 at 12:50 AM, Jarmo Pertman jarm...@gmail.com wrote: Or use rubyscript2exe, which also supports Linux and OSX. You can read more about it from here http://www.erikveen.dds.nl/rubyscript2exe/ On Feb 20, 10:38 am, Wilson Xu xu.xiaodong.wil...@gmail.com wrote: refer tohttp://rubyforge.org/projects/exerb/project. Wilson --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Watir General group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~--~~~~--~~--~--~---
[wtr-general] Re: How to change a ruby file into an .exe file
I have tried to use rubyscript2exe but it seems cannot run in my computer. Maybe it is a version problem. On Wed, Mar 18, 2009 at 8:57 AM, wesley chen cjq@gmail.com wrote: A problem exists: I create two .rb file in the same directory first is test1.rb, with code: require 'watir' $ie=Watir::IE.new second is test2.rb, with code: *require File.join(Dir.pwd, 'test1.rb')* $ie.goto(www.baidu.com) puts OK $ie.text_field(:id,'kw').set(www.baidu.com) $ie.button(:id,'sb').click puts OK $ie.close When I go to the right file directory, run rubyscript2exe test2.rb I get test2.exe, it can be executed as expected. Problem is: When I change the *require File.join(Dir.pwd, 'test1.rb')* to *require File.dirname(__FILE__) +'/test1.rb'* # *require File.dirname(__FILE__) +'\\test1.rb'* I can *rubyscript2exe test2.rb* into *test2.exe* as expected. But when I execute test2.exe, I get error message: *No such file to load --***\app\test1.rb(LoadError) * In my project, I use require File.dirname(__FILE__) + '/../..' anywhere, so how can make it so that, the exe file can be executed? Any suggestion would be quite appreciated. Thanks. Wesley Chen. On Wed, Mar 18, 2009 at 8:22 PM, wesley chen cjq@gmail.com wrote: Two steps to make the .rb file to .exe file. 1. go to your command line, run gem install rubyscript2exe 2. Go to your main.rb file directory, run rubyscript2exe main.rb It will make the main.rb into main.exe Thanks. Wesley Chen. On Sat, Feb 28, 2009 at 12:50 AM, Jarmo Pertman jarm...@gmail.comwrote: Or use rubyscript2exe, which also supports Linux and OSX. You can read more about it from here http://www.erikveen.dds.nl/rubyscript2exe/ On Feb 20, 10:38 am, Wilson Xu xu.xiaodong.wil...@gmail.com wrote: refer tohttp://rubyforge.org/projects/exerb/project. Wilson --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Watir General group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~--~~~~--~~--~--~---
[wtr-general] Re: How to change a ruby file into an .exe file
Just downloaded the gem and it seemed to work for me On Mar 18, 8:56 am, Rick Carter windchillfigh...@gmail.com wrote: I have tried to use rubyscript2exe but it seems cannot run in my computer. Maybe it is a version problem. On Wed, Mar 18, 2009 at 8:57 AM, wesley chen cjq@gmail.com wrote: A problem exists: I create two .rb file in the same directory first is test1.rb, with code: require 'watir' $ie=Watir::IE.new second is test2.rb, with code: *require File.join(Dir.pwd, 'test1.rb')* $ie.goto(www.baidu.com) puts OK $ie.text_field(:id,'kw').set(www.baidu.com) $ie.button(:id,'sb').click puts OK $ie.close When I go to the right file directory, run rubyscript2exe test2.rb I get test2.exe, it can be executed as expected. Problem is: When I change the *require File.join(Dir.pwd, 'test1.rb')* to *require File.dirname(__FILE__) +'/test1.rb'* # *require File.dirname(__FILE__) +'\\test1.rb'* I can *rubyscript2exe test2.rb* into *test2.exe* as expected. But when I execute test2.exe, I get error message: *No such file to load --***\app\test1.rb(LoadError) * In my project, I use require File.dirname(__FILE__) + '/../..' anywhere, so how can make it so that, the exe file can be executed? Any suggestion would be quite appreciated. Thanks. Wesley Chen. On Wed, Mar 18, 2009 at 8:22 PM, wesley chen cjq@gmail.com wrote: Two steps to make the .rb file to .exe file. 1. go to your command line, run gem install rubyscript2exe 2. Go to your main.rb file directory, run rubyscript2exe main.rb It will make the main.rb into main.exe Thanks. Wesley Chen. On Sat, Feb 28, 2009 at 12:50 AM, Jarmo Pertman jarm...@gmail.comwrote: Or use rubyscript2exe, which also supports Linux and OSX. You can read more about it from here http://www.erikveen.dds.nl/rubyscript2exe/ On Feb 20, 10:38 am, Wilson Xu xu.xiaodong.wil...@gmail.com wrote: refer tohttp://rubyforge.org/projects/exerb/project. Wilson --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Watir General group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~--~~~~--~~--~--~---
[wtr-general] Re: How to change a ruby file into an .exe file
refer to http://rubyforge.org/projects/exerb/ project. Wilson On Fri, Feb 20, 2009 at 4:34 PM, Jerry malar.je...@gmail.com wrote: Hi, I have one main program and some sub_programs.. Is their any way to convert these Ruby programs into a single .exe file? Thanx, Malar --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups Watir General group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~--~~~~--~~--~--~---