Skip to content

Commit

Permalink
Create tabix index to skip HTSJDK index creation
Browse files Browse the repository at this point in the history
  • Loading branch information
seppinho committed Oct 3, 2024
1 parent 8092031 commit e2bc234
Showing 1 changed file with 12 additions and 0 deletions.
12 changes: 12 additions & 0 deletions modules/local/quality_control/quality_control_vcf.nf
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,18 @@ process QUALITY_CONTROL_VCF {
set +e
echo '${JsonOutput.toJson(params.refpanel)}' > reference-panel.json
# Verify if VCF files are valid
for vcf in $vcf_files; do
# Attempt to create the index using tabix
if ! output=\$(tabix -p vcf "\$vcf" 2>&1); then
echo ::group type=error
echo "The provided VCF file is malformed."
echo "Error: \$output"
echo ::endgroup::
exit 1
fi
done
# TODO: create directories in java
mkdir ${chunksDir}
mkdir ${metaFilesDir}
Expand Down

0 comments on commit e2bc234

Please sign in to comment.