]> git.donarmstrong.com Git - mothur.git/blobdiff - systemcommand.cpp
added warning about merging with something above cutoff to cluster. working on chimeras
[mothur.git] / systemcommand.cpp
index 0820b0521961224c04f3b7c6207f4fd3d490c5fd..489a2f11f7c3a13df14bedf42a05339e86fcaeb2 100644 (file)
@@ -19,8 +19,18 @@ SystemCommand::SystemCommand(string option){
                if(option == "help") { help(); abort = true; }
                
                else {
-                       if (option = "") { mothurOut("You must enter a command to run."); mothurOutEndLine(); abort = true; }
-                       else { command = option; }
+                       if (option == "") { mothurOut("You must enter a command to run."); mothurOutEndLine(); abort = true; }
+                       else { 
+                               //check for outputdir and inputdir parameters
+                               int commaPos = option.find_first_of(',');
+                               
+                               //if there is a comma then grab string up to that pos
+                               if (commaPos != option.npos) {
+                                       option = option.substr(0, commaPos);
+                               }
+                       
+                               command = option;
+                       }
                }       
 
        }