name: bcftools_reheader
description: Reheader a VCF file
keywords:
  - reheader
  - vcf
  - update header
tools:
  - reheader:
      description: |
        Modify header of VCF/BCF files, change sample names.
      homepage: http://samtools.github.io/bcftools/bcftools.html
      documentation: http://samtools.github.io/bcftools/bcftools.html#reheader
      doi: 10.1093/gigascience/giab008
      licence: ["MIT"]
input:
  - meta:
      type: map
      description: |
        Groovy Map containing sample information
        e.g. [ id:'test', single_end:false ]
  - vcf:
      type: file
      description: VCF/BCF file
      pattern: "*.{vcf.gz,vcf,bcf}"
  - header:
      type: file
      description: New header to add to the VCF
      pattern: "*.{header.txt}"
  - samples:
      type: file
      description: File containing sample names to update (one sample per line)
      pattern: "*.{samples.txt}"
  - meta2:
      type: map
      description: |
        Groovy Map containing reference information
        e.g. [ id:'genome' ]
  - fai:
      type: file
      description: Fasta index to update header sequences with
      pattern: "*.{fai}"
output:
  - meta:
      type: map
      description: |
        Groovy Map containing sample information
        e.g. [ id:'test', single_end:false ]
  - versions:
      type: file
      description: File containing software versions
      pattern: "versions.yml"
  - vcf:
      type: file
      description: VCF with updated header, bgzipped per default
      pattern: "*.{vcf,vcf.gz,bcf,bcf.gz}"
authors:
  - "@bjohnnyd"
  - "@jemten"
  - "@ramprasadn"
maintainers:
  - "@bjohnnyd"
  - "@jemten"
  - "@ramprasadn"
