Skip to content

Commit

Permalink
Fix easy-complexsearch workflow shell scripting issues
Browse files Browse the repository at this point in the history
  • Loading branch information
milot-mirdita committed Dec 12, 2023
1 parent 75cc763 commit 10ba8f5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 10 deletions.
23 changes: 13 additions & 10 deletions data/easycomplexsearch.sh
Original file line number Diff line number Diff line change
Expand Up @@ -31,18 +31,20 @@ if notExists "${TMP_PATH}/result.dbtype"; then
"$MMSEQS" search "${QUERY}" "${TARGET}" "${TMP_PATH}/result" "${TMP_PATH}/search_tmp" ${SEARCH_PAR} \
|| fail "Search died"
fi
RESULT="${TMP_PATH}/result"

RESULT="${TMP_PATH}/result"
if [ "$PREFMODE" != "EXHAUSTIVE" ]; then
if notExists "${TMP_PATH}/result_expand_pref.dbtype"; then
"$MMSEQS" expandcomplex "${QUERY}" "${TARGET}" "${RESULT}" "${TMP_PATH}/result_expand_pref" \
if notExists "${TMP_PATH}/result_expand_pref.dbtype"; then
# shellcheck disable=SC2086
"$MMSEQS" expandcomplex "${QUERY}" "${TARGET}" "${RESULT}" "${TMP_PATH}/result_expand_pref" ${THREADS_PAR} \
|| fail "Expandcomplex died"
fi
if notExists "${TMP_PATH}/result_expand_aligned.dbtype"; then
"$MMSEQS" "$COMPLEX_ALIGNMENT_ALGO" "${QUERY}" "${TARGET}" "${TMP_PATH}/result_expand_pref" "${TMP_PATH}/result_expand_aligned" "${COMPLEX_ALIGN_PAR}" \
fi
if notExists "${TMP_PATH}/result_expand_aligned.dbtype"; then
# shellcheck disable=SC2086
"$MMSEQS" $COMPLEX_ALIGNMENT_ALGO "${QUERY}" "${TARGET}" "${TMP_PATH}/result_expand_pref" "${TMP_PATH}/result_expand_aligned" ${COMPLEX_ALIGN_PAR} \
|| fail "something died"
fi
RESULT="${TMP_PATH}/result_expand_aligned"
fi
RESULT="${TMP_PATH}/result_expand_aligned"
fi
if notExists "${TMP_PATH}/complex_result.dbtype"; then
# shellcheck disable=SC2086
Expand All @@ -63,8 +65,9 @@ fi
if [ -n "${REMOVE_TMP}" ]; then
# shellcheck disable=SC2086
"$MMSEQS" rmdb "${TMP_PATH}/result" ${VERBOSITY}
if [ "$PREFMODE" -ne "EXHAUSTIVE" ]; then
"$MMSEQS" rmdb "${TMP_PATH}/result_expand_aligned" "${VERBOSITY}"
if [ "$PREFMODE" != "EXHAUSTIVE" ]; then
# shellcheck disable=SC2086
"$MMSEQS" rmdb "${TMP_PATH}/result_expand_aligned" ${VERBOSITY}
fi
# shellcheck disable=SC2086
"$MMSEQS" rmdb "${TMP_PATH}/complex_result" ${VERBOSITY}
Expand Down
1 change: 1 addition & 0 deletions src/workflow/EasyComplexSearch.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,7 @@ int easycomplexsearch(int argc, const char **argv, const Command &command) {
cmd.addVariable("SCORECOMPLEX_PAR", par.createParameterString(par.scorecomplex).c_str());
cmd.addVariable("CONVERT_PAR", par.createParameterString(par.convertalignments).c_str());
cmd.addVariable("REPORT_PAR", par.createParameterString(par.createcomplexreport).c_str());
cmd.addVariable("THREADS_PAR", par.createParameterString(par.onlythreads).c_str());
cmd.addVariable("REMOVE_TMP", par.removeTmpFiles ? "TRUE" : NULL);
cmd.addVariable("VERBOSITY", par.createParameterString(par.onlyverbosity).c_str());
std::string program = tmpDir + "/easycomplexsearch.sh";
Expand Down

0 comments on commit 10ba8f5

Please sign in to comment.