[lnkForumImage]
TotalShareware - Download Free Software

Confronta i prezzi di migliaia di prodotti.
Asp Forum
 Home | Login | Register | Search 


 

Forums >

comp.lang.ruby

one click install for XP, not admin, no gems

Thufir Hawat

11/8/2007 11:53:00 PM

I notice this alert when installing Ruby:

Please review the ReadMe and License below.

* You must install as administrator on Windows NT,
2000, and XP in order for path and environment
variable settings to take effect.

I'm in XP and would like gems, but do not have Administrator
privileges. I can run ruby programs by typing the filename, foo.rb,
at the command prompt but, of course, I don't have a ruby command and
so no gems :(


-Thufir


7 Answers

Luis Lavena

11/9/2007 1:07:00 AM

0

On Nov 8, 8:53 pm, Thufir <hawat.thu...@gmail.com> wrote:
> I notice this alert when installing Ruby:
>
> Please review the ReadMe and License below.
>
> * You must install as administrator on Windows NT,
> 2000, and XP in order for path and environment
> variable settings to take effect.
>
> I'm in XP and would like gems, but do not have Administrator
> privileges. I can run ruby programs by typing the filename, foo.rb,
> at the command prompt but, of course, I don't have a ruby command and
> so no gems :(
>

The admin priviliges are required to change environment variable PATH
and also include RUBYOPT=rubygems that autoamtically load RubyGems for
you.

You can manually include the path doing:

SET PATH=%PATH%;C:\Ruby\bin

IN a command prompt. After that you should have 'gem', 'rake' and even
ruby commands available.

You can wrap that sentence in a batch file, but I don't have a Windows
machine handy right now to give you the exact details :-)

Maybe we should add a "Ruby Command Prompt" Icon in the Ruby programs
folder that do this for you.

Please, feel free to add this as Feature Request in the Tracker:
http://rubyforge.org/tracker/?atid=718&group_id=167&f...

Thufir Hawat

11/9/2007 4:01:00 AM

0

On Nov 8, 5:10 pm, Luis Lavena <luislav...@gmail.com> wrote:
[...]
> You can manually include the path doing:
>
> SET PATH=%PATH%;C:\Ruby\bin

My results:

C:\ruby\bin>
C:\ruby\bin>
C:\ruby\bin>ruby --version
ruby 1.8.6 (2007-09-24 patchlevel 111) [i386-mswin32]

C:\ruby\bin>
C:\ruby\bin>cd c:
C:\>
C:\>ruby
'ruby' is not recognized as an internal or external command,
operable program or batch file.

C:\>
C:\>SET PATH=%PATH%;C:\ruby\bin

C:\>
C:\>ruby
'ruby' is not recognized as an internal or external command,
operable program or batch file.

C:\>
C:\>



>
> IN a command prompt. After that you should have 'gem', 'rake' and even
> ruby commands available.
>
> You can wrap that sentence in a batch file, but I don't have a Windows
> machine handy right now to give you the exact details :-)

Bah! ;)

> Maybe we should add a "Ruby Command Prompt" Icon in the Ruby programs
> folder that do this for you.

Yes, pls. I'm often moving from computer to computer and may have to
install ruby from the get go.

> Please, feel free to add this as Feature Request in the Tracker:http://rubyforge.org/tracker/?atid=718&group_id=167&f...

Will do :)



thanks,

Thufir


Luis Lavena

11/9/2007 11:53:00 AM

0

On Nov 9, 1:00 am, Thufir <hawat.thu...@gmail.com> wrote:
>
> My results:
>
> C:\ruby\bin>
> C:\ruby\bin>
> C:\ruby\bin>ruby --version
> ruby 1.8.6 (2007-09-24 patchlevel 111) [i386-mswin32]
>
> C:\ruby\bin>
> C:\ruby\bin>cd c:>
> C:\>
> C:\>ruby
> 'ruby' is not recognized as an internal or external command,
> operable program or batch file.
>
> C:\>
> C:\>SET PATH=%PATH%;C:\ruby\bin
>
> C:\>
> C:\>ruby
> 'ruby' is not recognized as an internal or external command,
> operable program or batch file.
>

Weird that setting PATH manually didn't work...

Tried reproduce that locally and worked without problems...

Please don't tell me that you're using Windows Vista? :-P


Luis Lavena

11/9/2007 12:24:00 PM

0

On Nov 9, 1:00 am, Thufir <hawat.thu...@gmail.com> wrote:
> [...]
>

Ok, Adding Ruby to your PATH without administrative privileges:

Control Panel, System.
Go to Advanced and locate Environment Variables button lower in the
tab.

Under "User variables for ..." click New and fill with this
information:

Variable name: PATH
Variable value: C:\Ruby\bin

Click OK. Then OK again for Environment Variables dialog.

In a new Command Prompt window PATH should include now C:\Ruby\bin at
the end of the string.

> > Maybe we should add a "Ruby Command Prompt" Icon in the Ruby programs
> > folder that do this for you.
>
> Yes, pls. I'm often moving from computer to computer and may have to
> install ruby from the get go.
>

Oh, ruby on a stick! (RubyToGo! -- USB Ruby) ;-)

HTH,

Luis

Roger Pack

11/9/2007 8:25:00 PM

0

> C:\>SET PATH=%PATH%;C:\ruby\bin
>
> C:\>
> C:\>ruby
> 'ruby' is not recognized as an internal or external command,
> operable program or batch file.

Looks like this happens if path isn't already set to something (i.e. if
it ends up looking like
set
path=%path%;c:\ruby\bin

Also maybe adding 'non administrator' path setting might be an
interesting option for the OCI some time.
-Roger
--
Posted via http://www.ruby-....

Thufir Hawat

11/13/2007 6:06:00 AM

0

OCI==OP?

Haha, I'll have to try ruby on Vista, that'd be "interesting"...

Creating a new variable from the System Properties tab did the
trick :)


-Thufir


Thufir Hawat

11/13/2007 6:15:00 AM

0



On Nov 12, 10:05 pm, Thufir <hawat.thu...@gmail.com> wrote:
> OCI==OP?
[...]

One Click Installer, ok.


-Thufir