You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@groovy.apache.org by "wayyoung (JIRA)" <ji...@apache.org> on 2015/05/28 02:07:16 UTC

[jira] [Comment Edited] (GROOVY-6453) groovysh in Windows 7/8 doesn't support arrow keys and Del

    [ https://issues.apache.org/jira/browse/GROOVY-6453?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14562032#comment-14562032 ] 

wayyoung edited comment on GROOVY-6453 at 5/28/15 12:00 AM:
------------------------------------------------------------

I am using groovy2.4.3 + jline2 2.12.1 on windows 7 with Chinese locale. 
The arrow keys are not worked.
As your analyzing, I modified the isSystemIn(...) in WindowsTerminal.java from jline2 to always return true.
Now the arrow keys are worked.
Thank you very much!!



was (Author: wayyoung):
I am using groovy2.4.3 + jline2 2.12.1 on windows 7 with Chinese locale. 
The arrow keys is not worked.
As your analyzing, I modified the isSystemIn(...) in WindowsTerminal.java from jline2 to always return true.
Now the arrow keys are worked.
Thank you very much!!


> groovysh in Windows 7/8 doesn't support arrow keys and Del
> ----------------------------------------------------------
>
>                 Key: GROOVY-6453
>                 URL: https://issues.apache.org/jira/browse/GROOVY-6453
>             Project: Groovy
>          Issue Type: Bug
>          Components: Groovysh
>    Affects Versions: 2.2.0
>         Environment: Windows 8, 64bit (v6.2, build 9200), java version "1.7.0_45" SE Runtime Environment (build 1.7.0_45-b18) HotSpot 64-Bit Server VM (build 24.45-b08, mixed mode), Russian locale (!)
>            Reporter: Andrew P Fink
>              Labels: console, jline
>
> I have bare windows 8 with fresh JDK. I run Groovysh in cmd.exe.
> Groovysh 2.1.9 works as expected.
> Groovysh 2.2.0 doesn't react to arrow keys and Del, i.e. up key doesn't show previous command, left key doesn't shift cursor etc.
> After some investigation I found what is working:
> ctrl-a   go to beginning of line
> ctrl-e   go to End of line
> ctrl-f   go Forward one char
> ctrl-b   go Backward one char
> ctrl-d   delete the char
> ctrl-h   and backspace = delete left char
> ctrl-p   recall previous line
> ctrl-n   recall next line
> ctrl-s   search
> ctrl-r   reverse search 
> It's nice and feel myself like a Linux hacker, but I want arrow keys too ;-)
> I tried different options:
> - upgrade jline2.10 to 2.11 - no effect
> - --terminal=unix - it helps, but duplicate prompt (groovy:000>) and no more colors in console 
> Looks like problem lies in new jline v2 (groovysh 2.1.9 uses jline1.0)



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)