File tree Expand file tree Collapse file tree 3 files changed +12
-2
lines changed
frontend/src/main/scala/bloop Expand file tree Collapse file tree 3 files changed +12
-2
lines changed Original file line number Diff line number Diff line change @@ -139,7 +139,7 @@ object Interpreter {
139139 }
140140
141141 if (! bloop.util.CrossPlatform .isWindows)
142- state.logger.info(" \u001b [H \u001b [2J " )
142+ state.logger.info(bloop.util. Console .clearCommand )
143143
144144 // Force the first execution before relying on the file watching task
145145 fg(state).flatMap(newState => watcher.watch(newState, fg))
Original file line number Diff line number Diff line change @@ -42,7 +42,7 @@ final class SourceWatcher private (
4242 def runAction (state : State , events : Seq [DirectoryChangeEvent ]): Task [State ] = {
4343 // Windows is not supported for now
4444 if (! bloop.util.CrossPlatform .isWindows)
45- logger.info(" \u001b [H \u001b [2J " ) // Clean terminal before acting on the event action
45+ logger.info(bloop.util. Console .clearCommand)
4646 events.foreach(e => logger.debug(s " A ${e.eventType()} in ${e.path()} has triggered an event " ))
4747 action(state)
4848 }
Original file line number Diff line number Diff line change 1+ package bloop .util
2+
3+ object Console {
4+ private val escape = " \u001b ["
5+ private val cursorHome = " H"
6+ private val eraseScreen = " 2J"
7+ private val eraseScrollbar = " 3J"
8+
9+ val clearCommand : String = escape + cursorHome + escape + eraseScreen + escape + eraseScrollbar
10+ }
You can’t perform that action at this time.
0 commit comments