From a3a728e8671a0bd737bf112d4f60f5b9550b523c Mon Sep 17 00:00:00 2001 From: TZVanaalten Date: Fri, 25 Aug 2017 14:53:58 +0100 Subject: [PATCH] JAL-2629 fix for hmmbuild failing due to whitespace in the name --- src/jalview/hmmer/HMMBuildThread.java | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/jalview/hmmer/HMMBuildThread.java b/src/jalview/hmmer/HMMBuildThread.java index faba183..dc24d9e 100644 --- a/src/jalview/hmmer/HMMBuildThread.java +++ b/src/jalview/hmmer/HMMBuildThread.java @@ -296,6 +296,7 @@ public class HMMBuildThread implements Runnable { case "HMM Name": name = arg.getValue(); + name = name.trim(); break; case "Use Reference Annotation": command += "--hand "; @@ -306,7 +307,7 @@ public class HMMBuildThread implements Runnable } } - name = name.trim(); + if (name == null || "".equals(name)) { @@ -327,7 +328,7 @@ public class HMMBuildThread implements Runnable } } - command += "-n " + name + cmds.SPACE; + command += "-n " + name.replace(' ', '_') + cmds.SPACE; if (!alignment.isNucleotide()) { command += cmds.FORCEAMINO; // TODO check for rna -- 1.7.10.2