irb problems on one-click windows installer

R

Robert Feldt

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
 
C

Curt Hibbs

Robert said:
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
 
H

Henrik Horneber

Curt said:
Robert said:
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-talk/107774
 
S

Stephan Kämper

Robert said:
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-talk/107700
and there http://poignantguide.net/ruby/expansion-pak-1.html
(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
 
R

Robert Feldt

Henrik said:
Curt said:
Robert said:
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-talk/107774
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
 
H

Henrik Horneber

Robert said:
Henrik said:
Curt said:
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-talk/107774
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
 
F

Florian Gross

Robert said:
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.
 
G

gabriele renzi

Henrik Horneber ha scritto:
Robert said:
Henrik said:
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-talk/107774
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 :(
 
G

gabriele renzi

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)
 

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,755
Messages
2,569,536
Members
45,009
Latest member
GidgetGamb

Latest Threads

Top