EBIvariation / vcf-validator

Validation suite for Variant Call Format (VCF) files, implemented using C++11
Apache License 2.0
129 stars 39 forks source link

Stdout option for report #133

Closed srbcheema1 closed 6 years ago

srbcheema1 commented 6 years ago

This PR is to add stdout option in report options. This is to demonstrate the working of this new option for the issue #132

Usage: vcf-validator [OPTIONS] [< input_file]
Allowed options:
  -h [ --help ]                  Display this help
  -v [ --version ]               Display version of the validator
  -i [ --input ] arg (=stdin)    Path to the input VCF file, or stdin
  -l [ --level ] arg (=warning)  Validation level (error, warning, stop)
  -r [ --report ] arg (=summary) Comma separated values for types of reports 
                                 (summary, text, database, stdout)
  -o [ --outdir ] arg            Directory for the output

Users will be able to see reports on stdout without any need to opening file

user-pc~$ ./vcf_validator -i passed_meta_sample.vcf -r stdout
[info] Reading from input file...
Line 9: A valid 'reference' entry is not listed in the meta section. (warning)
Line 9: Chromosome/contig '1' is not described in a 'contig' meta description. (warning)
According to the VCF specification, the input file is valid
[info] According to the VCF specification, the input file is valid
user-pc~$ ./vcf_validator -i passed_meta_sample.vcf -r stdout,summary
[info] Reading from input file...
Line 9: A valid 'reference' entry is not listed in the meta section. (warning)
Line 9: Chromosome/contig '1' is not described in a 'contig' meta description. (warning)
According to the VCF specification, the input file is valid
[info] Summary report written to : passed_meta_sample.vcf.errors_summary.1522630855920.txt
[info] According to the VCF specification, the input file is valid
cyenyxe commented 6 years ago

Closed due to been a deprecated functionality.