From f169357f4e7a7b6e25acd5e4bdffc91679162631 Mon Sep 17 00:00:00 2001 From: mia Date: Sun, 7 Apr 2024 05:13:19 -0700 Subject: minor tweak --- src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main.rs') diff --git a/src/main.rs b/src/main.rs index 22ea865..e353666 100644 --- a/src/main.rs +++ b/src/main.rs @@ -137,6 +137,7 @@ fn highlight() { .unwrap_or_else(|_| PathBuf::from("/usr/share/cgit-syntect/scopes")); let scopes = std::fs::read_to_string(scope_dump) .unwrap() + .trim() .lines() .map(ScopeSelectors::from_str) .map(|sels| sels.unwrap()) @@ -217,7 +218,6 @@ fn highlight() { stdout.flush().unwrap(); line.clear(); if std::io::stdin().read_line(&mut line).unwrap() == 0 { - write!(&mut stdout, "\n").unwrap(); break; } if !line.ends_with('\n') { -- cgit 1.4.1