Up till now setting the `-a` flag of the `prompt_fresh_setup` theme resulted in duplicate prompts being printed to the terminal. The first, the interactive prompt with syntax highlighting, and a second after a call to the `clear` command without syntax highlighting. This patch replaces the old implementation with one which does not use `clear`. Instead it queries the terminal for the current cursor position, then uses this to move to the bottom of the terminal, print a number of new lines to move the stale command output off screen, and finally move almost back to the top ready for the invoked command to print it's output.
5.4 KiB
5.4 KiB