Uploaded image for project: 'Groovy'
  1. Groovy
  2. GROOVY-2034

Add JLine support to groovysh



    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.1-beta-3
    • Fix Version/s: 1.1-beta-3
    • Component/s: None
    • Labels:


      Hiya, I'd like to add JLine support to groovysh. JLine ( http://jline.sourceforge.net/ ) for those that don't know, is a really cool little library similar to editline/readline which allows Java CLI apps to have a very rich buffer editing/history/completion that most modern interactive CLI tools generally have.

      Its a tiny library (~60k) which is highly portable, working well on most modern Windows and POSIX compatible UNIX systems. For POSIX systems, it leverages the stty command to initialize the terminal in unbuffered mode, and on Windows uses a tiny .dll to get the same affect. It works very, very well and so far I've not heard of anyone having problems using it. It also has a fallback mode, which if on the off case that neither stty or the .dll bits work, that it will simply behave like normal Java console input/output... though I've yet to actually see a case where that fallback mode was kicked in.

      JLine is also BSD licensed, so no worries about tainting the distribution with GPL muck...

      The change is relatively small, and IMO the benefit is large.


        1. GROOVY-2034.diff
          44 kB
          Jason Dillon



            • Assignee:
              user57 Jason Dillon
              jason@planet57.com Jason Dillon
            • Votes:
              0 Vote for this issue
              0 Start watching this issue


              • Created: