[lnkForumImage]
TotalShareware - Download Free Software

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


 

Forums >

comp.lang.ruby

irb problems on one-click windows installer

Robert Feldt

11/4/2004 11:29:00 AM

Hi,

I have a couple of students that use Ruby in a course and they've run
into a problem that is not my home ground since I don't run Ruby from
the one-click installer. But maybe some of you have seen this problem:

After installing the latest one-click installer irb works from the
standard windows command line prompt (cmd) but they say they cannot use
curly {} or normal braces [] so cannot try out code easily.

Can this be a problem with the one-click installer irb or is it their
windows setup?

Any hints appreciated.

I've been trying to get them to install cygwin and run from their but
they are stubborn... ;)

Thanks,

Robert


9 Answers

Curt Hibbs

11/4/2004 11:36:00 AM

0

Robert Feldt wrote:
>
> Hi,
>
> I have a couple of students that use Ruby in a course and they've run
> into a problem that is not my home ground since I don't run Ruby from
> the one-click installer. But maybe some of you have seen this problem:
>
> After installing the latest one-click installer irb works from the
> standard windows command line prompt (cmd) but they say they cannot use
> curly {} or normal braces [] so cannot try out code easily.
>
> Can this be a problem with the one-click installer irb or is it their
> windows setup?
>
> Any hints appreciated.
>
> I've been trying to get them to install cygwin and run from their but
> they are stubborn... ;)

Are you using a non-english keyboard? If so, I know there are issues here
(which is beyond my expertise), but I have seen solutions posted to
ruby-talk. Try this google search (for example):

site:blade.nagaokaut.aazc.jp ruby irb german keyboard

Curt



Henrik Horneber

11/4/2004 11:37:00 AM

0

Curt Hibbs wrote:

> Robert Feldt wrote:
>
>>Hi,
>>
>>I have a couple of students that use Ruby in a course and they've run
>>into a problem that is not my home ground since I don't run Ruby from
>>the one-click installer. But maybe some of you have seen this problem:
>>
>>After installing the latest one-click installer irb works from the
>>standard windows command line prompt (cmd) but they say they cannot use
>>curly {} or normal braces [] so cannot try out code easily.
>>
>>Can this be a problem with the one-click installer irb or is it their
>>windows setup?
>>
>>Any hints appreciated.
>>
>>I've been trying to get them to install cygwin and run from their but
>>they are stubborn... ;)
>
>
> Are you using a non-english keyboard? If so, I know there are issues here
> (which is beyond my expertise), but I have seen solutions posted to
> ruby-talk. Try this google search (for example):
>
> site:blade.nagaokaut.aazc.jp ruby irb german keyboard
>
> Curt
>
>
>
http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-t...


Stephan Kämper

11/4/2004 11:44:00 AM

0

Robert Feldt wrote:

> Hi,
>
> I have a couple of students that use Ruby in a course and they've run
> into a problem that is not my home ground since I don't run Ruby from
> the one-click installer. But maybe some of you have seen this problem:
>
> After installing the latest one-click installer irb works from the
> standard windows command line prompt (cmd) but they say they cannot use
> curly {} or normal braces [] so cannot try out code easily.
>
> Can this be a problem with the one-click installer irb or is it their
> windows setup?

That was discussed here
http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-t...
and there http://poignantguide.net/ruby/expansion-...
(the latter being the funnier link, thanks to why_).

Do they also have problems with '\', '|', '@' and '~'. In that case they
might try to create '.inputrc' in their home directories and put the
following lines into that file

"\M-[": "["
"\M-]": "]"
"\M-{": "{"
"\M-}": "}"
"\M-\\": "\\"
"\M-|": "|"
"\M-@": "@"
"\M-~": "~"

They might need to patch some of the settings, depending on the keyboard
layout. The above lines fit my German keyboard layout. In Sweden YMMV.

> Any hints appreciated.
>
> I've been trying to get them to install cygwin and run from their but
> they are stubborn... ;)

They might try Linux... ;-)

Stephan

Robert Feldt

11/4/2004 11:45:00 AM

0

Henrik Horneber wrote:

> Curt Hibbs wrote:
>
>> Robert Feldt wrote:
>>
>>> Hi,
>>>
>>> I have a couple of students that use Ruby in a course and they've run
>>> into a problem that is not my home ground since I don't run Ruby from
>>> the one-click installer. But maybe some of you have seen this problem:
>>>
>>> After installing the latest one-click installer irb works from the
>>> standard windows command line prompt (cmd) but they say they cannot use
>>> curly {} or normal braces [] so cannot try out code easily.
>>>
>>> Can this be a problem with the one-click installer irb or is it their
>>> windows setup?
>>>
>>> Any hints appreciated.
>>>
>>> I've been trying to get them to install cygwin and run from their but
>>> they are stubborn... ;)
>>
>>
>>
>> Are you using a non-english keyboard? If so, I know there are issues
>> here
>> (which is beyond my expertise), but I have seen solutions posted to
>> ruby-talk. Try this google search (for example):
>>
>> site:blade.nagaokaut.aazc.jp ruby irb german keyboard
>>
>> Curt
>>
>>
>>
> http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-t...
>
Thanks to both of you.

Yes, they are on non-US keyboards.

Sorry I missed the posts. I will look around but the students are not on
mingw32 so I'm not sure there is an inputrc on plain windows. Maybe it
can help them find a solution though. If anyone already has found it
please share.

Thanks,

Robert



Henrik Horneber

11/4/2004 11:55:00 AM

0

Robert Feldt wrote:

> Henrik Horneber wrote:
>
>> Curt Hibbs wrote:
>>
>>> Robert Feldt wrote:
>>>
>>>> Hi,
>>>>
>>>> I have a couple of students that use Ruby in a course and they've run
>>>> into a problem that is not my home ground since I don't run Ruby from
>>>> the one-click installer. But maybe some of you have seen this problem:
>>>>
>>>> After installing the latest one-click installer irb works from the
>>>> standard windows command line prompt (cmd) but they say they cannot use
>>>> curly {} or normal braces [] so cannot try out code easily.
>>>>
>>>> Can this be a problem with the one-click installer irb or is it their
>>>> windows setup?
>>>>
>>>> Any hints appreciated.
>>>>
>>>> I've been trying to get them to install cygwin and run from their but
>>>> they are stubborn... ;)
>>>
>>>
>>>
>>>
>>> Are you using a non-english keyboard? If so, I know there are issues
>>> here
>>> (which is beyond my expertise), but I have seen solutions posted to
>>> ruby-talk. Try this google search (for example):
>>>
>>> site:blade.nagaokaut.aazc.jp ruby irb german keyboard
>>>
>>> Curt
>>>
>>>
>>>
>> http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-t...
>>
> Thanks to both of you.
>
> Yes, they are on non-US keyboards.
>
> Sorry I missed the posts. I will look around but the students are not on
> mingw32 so I'm not sure there is an inputrc on plain windows.


If they are using the latest One-Click-Installer, the instructions given
by eban work. At least for me.

regards,
Henrik




Florian Gross

11/4/2004 12:34:00 PM

0

Robert Feldt wrote:

> I have a couple of students that use Ruby in a course and they've run
> into a problem that is not my home ground since I don't run Ruby from
> the one-click installer. But maybe some of you have seen this problem:
>
> After installing the latest one-click installer irb works from the
> standard windows command line prompt (cmd) but they say they cannot use
> curly {} or normal braces [] so cannot try out code easily.

Another problem is that Ctrl-Left/Right don't do word-wise cursor
movement. I know of no good way of fixing this (the issue seems to be
readline not receiving the Ctrl-flag for cursor keys), but
Alt-Left/Right can be mapped:

"\M-\e[D": backward-word
"\M-\e[C": forward-word

If anybody knows of a way to get Ctrl-Left/Right to work with cmd (I
know it works with rxvt, but that usually isn't an option) I'd really
like to know about it.

And irb doesn't even do anything when run with the --no-readline option
for me. This is IMHO a big problem because readline support is only
really needed when you want to use tab-completion anyway. (And I'm not
even sure if tab-completion is worth it -- last time I checked it wasn't
even intelligent about only listing methods that the object actually
responds to...)

So I'd suggest that the --no-readline option of irb should disable
readline support and that the one click installer should include a
default .inputrc.

gabriele renzi

11/4/2004 1:06:00 PM

0

Henrik Horneber ha scritto:

> Robert Feldt wrote:
>
>> Henrik Horneber wrote:
>>
>>> Curt Hibbs wrote:
>>>
>>>> Robert Feldt wrote:
>>>>
>>>>> Hi,
>>>>>
>>>>> I have a couple of students that use Ruby in a course and they've run
>>>>> into a problem that is not my home ground since I don't run Ruby from
>>>>> the one-click installer. But maybe some of you have seen this problem:
>>>>>
>>>>> After installing the latest one-click installer irb works from the
>>>>> standard windows command line prompt (cmd) but they say they cannot
>>>>> use
>>>>> curly {} or normal braces [] so cannot try out code easily.
>>>>>
>>>>> Can this be a problem with the one-click installer irb or is it their
>>>>> windows setup?
>>>>>
>>>>> Any hints appreciated.
>>>>>
>>>>> I've been trying to get them to install cygwin and run from their but
>>>>> they are stubborn... ;)
>>>>
>>>>
>>>>
>>>>
>>>>
>>>> Are you using a non-english keyboard? If so, I know there are issues
>>>> here
>>>> (which is beyond my expertise), but I have seen solutions posted to
>>>> ruby-talk. Try this google search (for example):
>>>>
>>>> site:blade.nagaokaut.aazc.jp ruby irb german keyboard
>>>>
>>>> Curt
>>>>
>>>>
>>>>
>>> http://blade.nagaokaut.ac.jp/cgi-bin/scat.rb/ruby/ruby-t...
>>>
>> Thanks to both of you.
>>
>> Yes, they are on non-US keyboards.
>>
>> Sorry I missed the posts. I will look around but the students are not
>> on mingw32 so I'm not sure there is an inputrc on plain windows.
>
>
>
> If they are using the latest One-Click-Installer, the instructions given
> by eban work. At least for me.
>

agreed, they work for me, even if from time to time I end up typing some
strange character and irb crahes :/

PS
my inpoutrc is
"\M-[": "["
"\M-]": "]"
"\M-{": "{"
"\M-}": "}"
"\M-\\": "\\"
"\M-|": "|"
"\M-@": "@"
"\M-": ""
"\M-\3760": "}"
"\M-\3767": "{"
"\M-\3768": "("
"\M-\3769": ")"
"\M-\e[3~": delete-char

but 'del' never really worked for me :(

gabriele renzi

11/4/2004 1:09:00 PM

0

Florian Gross ha scritto:


> So I'd suggest that the --no-readline option of irb should disable
> readline support and that the one click installer should include a
> default .inputrc.

I strongly agree, FWIW.
Also, while we're at it: why irb does not use optaparse?
I'm getting byte every time I do something like
irb -roptparse (note the missing space beetween -r and the argument)

Curt Hibbs

11/4/2004 2:35:00 PM

0

gabriele renzi wrote:
>
> Florian Gross ha scritto:
>
>
> > So I'd suggest that the --no-readline option of irb should disable
> > readline support and that the one click installer should include a
> > default .inputrc.
>
> I strongly agree, FWIW.

I'm adding this to my to-do list.

Curt