Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix for text echo issue when running sbt. #3507

Merged
merged 3 commits into from Sep 14, 2017
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -119,8 +119,9 @@ private[sbt] object JLine {
*/
def usingTerminal[T](f: jline.Terminal => T): T =
withTerminal { t =>
val result = f(t)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Javadoc comment says "This ensures synchronized access as well as re-enabling echo after getting the Terminal.", so I am guessing that you'd need to call t.restore both before and after f(t).

t.restore
f(t)
result
}

def createReader(): ConsoleReader = createReader(None, JLine.makeInputStream(true))
Expand Down