On Dec 12, 2007, at 6:58 PM, Jyri Virkki wrote:

> David Van Couvering wrote:
>>
>> - The next window says:
>>
>> "Ruby Gems is not accessible"
>>
>> If you click on [Details] it says "The 'gem' tool is installed on  
>> your
>> system, but the gem repository could not be found.  You may try to  
>> set
>> $GEM_HOME and run IDE again"
>
> For some reason looks like netbeans doesn't pick up the gem
> environment. It should ideally do so automatically like in the CLI:

I think Martin is planning on doing this as part of the platform  
manager work.

For the 6.0 fix branch, we can also apply a simple fix similar to  
what I did for Debian (where I added the specific default path where  
gems are located for Debian/Ubuntu when it's not found elsewhere).

>> Update: I was able to install Rails after making /usr/ruby/1.8/bin
>> writeable.  I'll log another issue to make this directory writeable.
>
> The system dir isn't meant to be world-writable.
>
> Users can do private gem installs via -i,
>
> % gem help install
> [...]
>     -i, --install-dir DIR            Gem repository directory to  
> get installed
>                                      gems.
> [...]
>
> It'd be nice if gem had a built-in default (say, $HOME) for
> non-privileged users. That might be a good idea to propose to the gem
> community.

I wrote to this alias a while ago about this problem.  Basically, I  
think we want to run the "gem" command as root, but NOT the IDE.

On Linux this is pretty easy; launch gem via the gksu command. This  
will produce the familiar system "enter your admin password" dialog  
and then run the subprocess as root as appropriate, and the install  
should succeed.

Is the same command available on Solaris? If so, we can probably do  
this fairly simply. (I started on this work a while back, but  
abandoned it when I discovered that this was much trickier on OSX and  
Windows.).

-- Tor


Reply via email to