EXE in windows

D

Daniel Peikes

I am new to Ruby (not to programming) and am trying to make executable
files in Windows. The doc I am looking at only seems to have
instructions for exe's on unix/linux. Any advise on who to do this or
whre to look to figure it out


********************************************************************************
http://www.math.umd.edu/~dcarrera/ruby/0.3/chp_01/programs.html
Making programs executable
If you are running Linux or Unix, you can make your Ruby programs
executable, so they can be run like any other program.


First, you need to know where Ruby is installed in your system. Type
'which ruby' on a terminal:


Precede this by '#!' (pronounced "sharp bang") and make that the very
first line of your program.


Now you can type 'chmod +x prog.rb' to make the program executable ('+x'
means "executable").


Warning: Make sure that you type this exactly and that it's the very
first line of your program.
If there is a blank line above this one, this won't work.
If there is a space before the '#!',this won't work.
********************************************************************************
 
T

tho_mica_l

Precede this by '#!' (pronounced "sharp bang") and make that the very
first line of your program.

On windows, you could also create a new filetype (eg .rbx) and
associate
it with ruby as the application that opens file with this extension.
This would allow you to double-click on rbx-files.

A second solution besides rubyscript2exe is exerb[1]. The
disadvantage
with exerb is that, at least the last time I looked into it, only
little
documentation was available in English. Also I think that exerb works
less well with complex compiled extensions but this could also be a
now
outdated misjudgment on my part resulting from a certain lack of
accessible documentation.

Regards,
Thomas.


[1] http://raa.ruby-lang.org/project/exerb/
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,774
Messages
2,569,596
Members
45,128
Latest member
ElwoodPhil
Top