mix-test.watch
mix-test.watch copied to clipboard
Clear screen and scroll history
This is more of a feature request which I can try via a PR if I can get some confirmation that it makes sense and would be considered:
The clear: true
option clears the terminal screen but not it's history. This means that despite cleaning the screen, it's not easy to scroll back to the beginning of the most recent test run. That's because the terminal remembers the whole history since the beginning of the session.
https://github.com/lpil/mix-test.watch/blob/345bf7d0df1bf0b6e6cce18db0ae3a36a306aaaf/lib/mix_test_watch/runner.ex#L32e
One possible approach could be to make it optional so that clear would actually run:
clear && printf '\e[3J'
I am not sure what's the equivalent for printf '\e[3J'
using IO.ANSI
.