Skip to content

Commit

Permalink
Merge pull request #5648 from mvdbeek/snpeff_no_broken_symlinks
Browse files Browse the repository at this point in the history
Fix snpeffdb output to not contain broken symlinks
  • Loading branch information
mvdbeek authored Nov 22, 2023
2 parents 025a0d7 + ac5edc4 commit af2e922
Showing 1 changed file with 11 additions and 9 deletions.
20 changes: 11 additions & 9 deletions tool_collections/snpeff/snpEff_create_db.xml
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
<tool id="snpEff_build_gb" name="SnpEff build:" version="@WRAPPER_VERSION@.galaxy5">
<tool id="snpEff_build_gb" name="SnpEff build:" version="@WRAPPER_VERSION@.galaxy6" profile="22.01">
<description> database from Genbank or GFF record</description>
<macros>
<import>snpEff_macros.xml</import>
Expand All @@ -14,25 +14,26 @@
python3 '$__tool_directory__/gbk2fa.py' '${input_type.input}' '${output_fasta}' ${input_type.remove_version} &&
#end if
mkdir -p '${snpeff_output.files_path}'/'${genome_version}' &&
mkdir -p '${snpeff_output.files_path}/${genome_version}' &&
mkdir -p snpeff_output/'${genome_version}' &&
#if str($input_type.input_type_selector) == "gb":
#if $input_type.input.is_of_type("genbank"):
ln -s '${input_type.input}' '${snpeff_output.files_path}/${genome_version}/genes.gbk' &&
ln -s '${input_type.input}' 'snpeff_output/${genome_version}/genes.gbk' &&
#elif $input_type.input.is_of_type("genbank.gz"):
ln -s '${input_type.input}' '${snpeff_output.files_path}/${genome_version}/genes.gbk.gz' &&
ln -s '${input_type.input}' 'snpeff_output/${genome_version}/genes.gbk.gz' &&
#end if
#else:
#if $input_type.reference_source.reference_source_selector == "history":
#if $input_type.reference_source.input_fasta.is_of_type("fasta"):
ln -s '${input_type.reference_source.input_fasta}' '${snpeff_output.files_path}/${genome_version}/sequences.fa' &&
ln -s '${input_type.reference_source.input_fasta}' 'snpeff_output/${genome_version}/sequences.fa' &&
#elif $input_type.reference_source.input_fasta.is_of_type("fasta.gz"):
ln -s '${input_type.reference_source.input_fasta}' '${snpeff_output.files_path}/${genome_version}/sequences.fa.gz' &&
ln -s '${input_type.reference_source.input_fasta}' 'snpeff_output/${genome_version}/sequences.fa.gz' &&
#end if
#elif $input_type.reference_source.reference_source_selector == "cached":
ln -s '${input_type.reference_source.ref_file.fields.path}' '${snpeff_output.files_path}/${genome_version}/sequences.fa' &&
ln -s '${input_type.reference_source.ref_file.fields.path}' 'snpeff_output/${genome_version}/sequences.fa' &&
#end if
ln -s '${input_type.input}' '${snpeff_output.files_path}/${genome_version}/genes.${input_type.input_type_selector}' &&
ln -s '${input_type.input}' 'snpeff_output/${genome_version}/genes.${input_type.input_type_selector}' &&
#end if
snpEff @JAVA_OPTIONS@ build -v
Expand All @@ -45,7 +46,8 @@
#elif str($input_type.input_type_selector) == "gtf":
-gtf22
#end if
-dataDir '${snpeff_output.files_path}' '${genome_version}' &&
-dataDir "\$(pwd)/snpeff_output" '${genome_version}' &&
mv snpeff_output/'${genome_version}'/*.bin '${snpeff_output.files_path}/${genome_version}' &&
echo '${genome_version}.genome : ${genome_version}' >> '${snpeff_output.files_path}'/snpEff.config &&
echo '${genome_version}.codonTable : ${codon_table}' >> '${snpeff_output.files_path}'/snpEff.config
]]></command>
Expand Down

0 comments on commit af2e922

Please sign in to comment.