Ctrl+C handling (#75)

As stated [here](https://doc.rust-lang.org/std/io/trait.BufRead.html#errors-1), `read_until` (and `read_line`) ignore Ctrl+C, so Topgrade does not respond to Ctrl+C in the retry prompt, and instead will exit only when enter is pressed after Ctrl+C. This is undesirable, so this pull request is a WIP until we find a solution.
This commit is contained in:
Roey Darwish Dror
2018-10-17 14:07:58 +03:00
committed by GitHub
parent 41621bd08f
commit a6b6b7aa4e
7 changed files with 385 additions and 81 deletions

7
src/ctrlc/windows.rs Normal file
View File

@@ -0,0 +1,7 @@
pub fn running() -> bool {
true
}
pub fn set_running(_value: bool) {}
pub fn set_handler() {}