Questions tagged [jline2]

JLine 2.x is an evolution of JLine 1.x, a Java library for handling console input. It is similar in functionality to BSD editline and GNU readline.

JLine2 is a Java library for handling console input. It is similar in functionality to BSD editline and GNU readline. People familiar with the readline/editline capabilities for modern shells (such as bash and tcsh) will find most of the command editing features of JLine to be familiar.

JLine 2.x is an evolution of JLine 1.x.

9 questions
8
votes
1 answer

jline2 print "^J" when it should print "\n" on a telnet console

I am using JLine 2 (v2.13) in conjunction with a Socket IO to create an admin console for my app which can be accessed via an ordinary telnet client. However I found it prints out strange symbols when it should print out a line…
Gelin Luo
  • 13,399
  • 23
  • 77
  • 119
3
votes
1 answer

How can I make JShell stop wrapping lines back on themselves?

I'm using JDK 9 build 179 on Windows 7. I've got the "Screen Buffer Size Width" property of my Windows 7 command shell, set to a large number because that's the way I roll. That works fine normally; when I'm simply using the Windows shell on its…
3
votes
2 answers

Java Command-Line App with own prompt

I'm writing a JAVA-Console-Application. After the user started the jar he should get a Commandline like the Linux shell, where he can enter commands. This is something I never programmed before. Normaly im writing GUI's or I start the jar with some…
Daniel
  • 1,007
  • 1
  • 7
  • 22
1
vote
0 answers

Is it possbile to identify Double Tab key press in Jline2 with Java

I am generating a CLI interface using Jline2 with Java 1.7. I need to capture double tab key press in my console reader. Is it possible , if so please let me know how to implement the same.
Nagarajan
  • 11
  • 1
0
votes
0 answers

Jline input disrupted by System out

I'm having some trouble with Jline and not quite understanding how to work it properly, everything seems to work from the examples but when i attempt to move it into my console application things go weird. I've come across two issues: When you…
Jakeinzah
  • 25
  • 1
  • 6
0
votes
1 answer

Java SSH server with JLine3 and JSch client

I'm trying to migrate a Java based SSH server using apache sshd-core from using jline2 to jline3 and using a JSch client to connect and execute shell commands. With jline2, everything works just fine. With jline3, it works just fine when executing…
anand1st
  • 378
  • 4
  • 13
0
votes
1 answer

Display a string just for a few seconds with JLine2

I am using JLine 2 to write a console application in Java. I need to make a password visible on the console for say 10 seconds, then erase it (on a GNU terminal). I tried different things, amongst which : putString(pass); Thread.sleep(10*1000);…
Derlin
  • 8,518
  • 2
  • 22
  • 42
0
votes
1 answer

Java Console Application with jLine

I have a multi thread java console application. One of the threads is reading input from the user while other prints to the console some data. The problem shows up when the writer thread print something while user is typing an input. It interrupts…
Bünyamin Sarıgül
  • 2,689
  • 4
  • 25
  • 50
0
votes
1 answer

First Character is not getting detected/printed using Jline 2.14 with java

int readChar = cnslRdr.readCharacter(); if ( readChar == 9){ if (cnslRdr.readCharacter() == 9 ){ cnslRdr.println("Double tab presssed.."); …
Nagarajan
  • 11
  • 1