Add trimsuffix to remove windows line endings

This commit is contained in:
Paul Kramme 2017-12-26 17:58:26 +01:00 committed by GitHub
parent 1634d7630d
commit 8d453096f9
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -32,6 +32,7 @@ func main() {
fmt.Println(err)
return
}
input = strings.TrimSuffix(input, "\r\n")
input = strings.Trim(input[:len(input)-1], " ")
if input == ".exit" {
break