From 07bc781c3d866baf641f8545a38aefb22d2eeac3 Mon Sep 17 00:00:00 2001 From: Arne Keller Date: Sun, 16 Feb 2020 16:25:01 +0100 Subject: [PATCH] Skip comments instead of exiting --- src/edu/kit/informatik/ui/CommandLine.java | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/edu/kit/informatik/ui/CommandLine.java b/src/edu/kit/informatik/ui/CommandLine.java index d4e8b54..bf52c52 100644 --- a/src/edu/kit/informatik/ui/CommandLine.java +++ b/src/edu/kit/informatik/ui/CommandLine.java @@ -23,9 +23,12 @@ public class CommandLine { while (true) { final String input = Terminal.readLine(); - if (input == null || input.startsWith("#")) { + if (input == null) { break; // TODO remove } + if (input.startsWith('#')) { + continue; // TODO remove + } if (input.equals(EXIT)) { break;