]> git.donarmstrong.com Git - mothur.git/blobdiff - engine.cpp
fixes while testing 1.33.0
[mothur.git] / engine.cpp
index 48f782ab2a590d71a292e7b83125ba8ce0f3fffe..d6be4e4f1a16e00af29cfe36052c98e3a6e98efb 100644 (file)
@@ -65,7 +65,9 @@ bool InteractEngine::getInput(){
                                if (pid == 0) {
                                
                        #endif
-                       
+                    
+                       if (mout->changedSeqNames) { mout->mothurOut("[WARNING]: your sequence names contained ':'.  I changed them to '_' to avoid problems in your downstream analysis.\n"); }
+                    
                        mout->mothurOutEndLine();
                        
                        input = getCommand();   
@@ -115,15 +117,18 @@ bool InteractEngine::getInput(){
                                        //cout << pid << " is in execute " << commandName << endl;
                                        #endif
                                        //executes valid command
+                    mout->changedSeqNames = false;
                                        mout->runParse = true;
                                        mout->clearGroups();
                                        mout->clearAllGroups();
                                        mout->Treenames.clear();
                                        mout->saveNextLabel = "";
-                                       mout->printedHeaders = false;
-                                       mout->commandInputsConvertError = false;
-                                       mout->currentBinLabels.clear();
-                                       mout->binLabelsInFile.clear();
+                    mout->commandInputsConvertError = false;
+                                       mout->printedSharedHeaders = false;
+                                       mout->currentSharedBinLabels.clear();
+                                       mout->sharedBinLabelsInFile.clear();
+                    mout->printedListHeaders = false;
+                    mout->listBinLabelsInFile.clear();
                                                        
                                        Command* command = cFactory->getCommand(commandName, options);
                                        if (mout->commandInputsConvertError) { quitCommandCalled = 2; }
@@ -276,7 +281,7 @@ bool BatchEngine::getInput(){
                        
                        
                        if (input[0] != '#') {
-                               
+                               if (mout->changedSeqNames) { mout->mothurOut("[WARNING]: your sequence names contained ':'.  I changed them to '_' to avoid problems in your downstream analysis.\n"); }
                                mout->mothurOutEndLine();
                                mout->mothurOut("mothur > " + input);
                                mout->mothurOutEndLine();
@@ -300,15 +305,18 @@ bool BatchEngine::getInput(){
                                                if ((cFactory->MPIEnabled(commandName)) || (pid == 0)) {
                                        #endif
                                        //executes valid command
+                    mout->changedSeqNames = false;
                                        mout->runParse = true;
                                        mout->clearGroups();
                                        mout->clearAllGroups();
                                        mout->Treenames.clear();
                                        mout->saveNextLabel = "";
-                                       mout->printedHeaders = false;
                                        mout->commandInputsConvertError = false;
-                                       mout->currentBinLabels.clear();
-                                       mout->binLabelsInFile.clear();
+                    mout->printedSharedHeaders = false;
+                    mout->currentSharedBinLabels.clear();
+                    mout->sharedBinLabelsInFile.clear();
+                    mout->printedListHeaders = false;
+                    mout->listBinLabelsInFile.clear();
 
                                                        
                                        Command* command = cFactory->getCommand(commandName, options);
@@ -413,6 +421,8 @@ bool ScriptEngine::getInput(){
                        input = getNextCommand(listOfCommands); 
                        
                        if (input == "") { input = "quit()"; }
+                    
+            if (mout->changedSeqNames) { mout->mothurOut("[WARNING]: your sequence names contained ':'.  I changed them to '_' to avoid problems in your downstream analysis.\n"); }
                        
                        if (mout->gui) {
                                if ((input.find("quit") != string::npos) || (input.find("set.logfile") != string::npos)) {}
@@ -468,15 +478,18 @@ bool ScriptEngine::getInput(){
                                                        //cout << pid << " is in execute" << endl;      
                                        #endif
                                        //executes valid command
+                    mout->changedSeqNames = false;
                                        mout->runParse = true;
                                        mout->clearGroups();
                                        mout->clearAllGroups();
                                        mout->Treenames.clear();
                                        mout->saveNextLabel = "";
-                                       mout->printedHeaders = false;
-                                       mout->commandInputsConvertError = false;
-                                       mout->currentBinLabels.clear();
-                                       mout->binLabelsInFile.clear();
+                    mout->commandInputsConvertError = false;
+                    mout->printedSharedHeaders = false;
+                    mout->currentSharedBinLabels.clear();
+                    mout->sharedBinLabelsInFile.clear();
+                    mout->printedListHeaders = false;
+                    mout->listBinLabelsInFile.clear();
 
                                        Command* command = cFactory->getCommand(commandName, options);
                                        if (mout->commandInputsConvertError) { quitCommandCalled = 2; }