From: westcott Date: Tue, 2 Jun 2009 16:10:12 +0000 (+0000) Subject: allow user to input quit instead of quit() X-Git-Url: https://git.donarmstrong.com/?p=mothur.git;a=commitdiff_plain;h=a2edaadb975e5cb5d6cf68353bfe95f53235600d allow user to input quit instead of quit() --- diff --git a/engine.cpp b/engine.cpp index 11d738d..add84b9 100644 --- a/engine.cpp +++ b/engine.cpp @@ -64,6 +64,9 @@ bool InteractEngine::getInput(){ getline(cin, input); if (cin.eof()) { input = "quit()"; } + //allow user to omit the () on the quit command + if (input == "quit") { input = "quit()"; } + errorFree = errorCheckor->checkInput(input); if (errorFree == true) { CommandOptionParser parser(input); @@ -145,6 +148,10 @@ bool BatchEngine::getInput(){ if (inputBatchFile.eof()) { input = "quit()"; } cout << endl << "mothur > " << input << endl; + + //allow user to omit the () on the quit command + if (input == "quit") { input = "quit()"; } + errorFree = errorCheckor->checkInput(input); if (errorFree == true) { CommandOptionParser parser(input);