Very rough implementation of line count

This commit is contained in:
Jamie Hardt
2021-05-17 23:04:38 -07:00
parent 8a067984eb
commit 2aca5a3e8f
4 changed files with 115 additions and 1 deletions

View File

@@ -13,6 +13,7 @@ from .reporting import print_section_header_style, print_status_style, print_war
from .validations import *
from ptulsconv.pdf.supervisor_1pg import output_report as output_supervisor_1pg
from ptulsconv.pdf.line_count import output_report as output_line_count
# field_map maps tags in the text export to fields in FMPXMLRESULT
# - tuple field 0 is a list of tags, the first tag with contents will be used as source
@@ -217,7 +218,9 @@ def convert(input_file, output_format='fmpxml', start=None, end=None, select_ree
json.dump(normalize_record_keys(parsed), output)
elif output_format == 'full':
print("Sorry, the `full` output type is not yet supported.")
output_supervisor_1pg(normalize_record_keys(parsed))
normalized_records = normalize_record_keys(parsed)
output_supervisor_1pg(normalized_records)
output_line_count(normalized_records)
elif output_format == 'fmpxml':
if xsl is None:
fmp_dump(parsed, input_file, output)