]> git.donarmstrong.com Git - mothur.git/blobdiff - chimeraslayercommand.cpp
fixed bug in chimera.uchime
[mothur.git] / chimeraslayercommand.cpp
index 8835290a8a0208fec200a4d0620d3760f3e837ae..a422c8883ea9f172fe076961fa7705cb548e767e 100644 (file)
@@ -112,6 +112,7 @@ ChimeraSlayerCommand::ChimeraSlayerCommand(string option)  {
                
                //allow user to run help
                if(option == "help") { help(); abort = true; calledHelp = true; }
+               else if(option == "citation") { citation(); abort = true; calledHelp = true;}
                
                else {
                        vector<string> myArray = setParameters();
@@ -304,9 +305,10 @@ ChimeraSlayerCommand::ChimeraSlayerCommand(string option)  {
                                        
                                        templatefile = validParameter.validFile(parameters, "reference", true);
                                        if (templatefile == "not open") { abort = true; }
-                                       else if (templatefile == "not found") { templatefile = "";  m->mothurOut("reference is a required parameter for the chimera.slayer command."); m->mothurOutEndLine(); abort = true;  }  
+                                       else if (templatefile == "not found") { templatefile = "";  m->mothurOut("reference is a required parameter for the chimera.slayer command, unless and namefile is given."); m->mothurOutEndLine(); abort = true;  }    
                                }
-                       }
+                       }else if (hasName) {  templatefile = "self"; }
+                       else { templatefile = "";  m->mothurOut("reference is a required parameter for the chimera.slayer command."); m->mothurOutEndLine(); abort = true;  }   
                        
                        string temp = validParameter.validFile(parameters, "processors", false);        if (temp == "not found"){       temp = m->getProcessors();      }
                        m->setProcessors(temp);