This addresses one big open issue and several other small ones:
Merge the functionality of wb-blank into wb-fillable (closes #17)
- Some refactoring to turn chunks of code into reusable functions, especially where code was repeated
- Blank sheet can now be produced with --blank flag instead of calling a separate script
- Revise documentation to reflect this change
- Delete wb-blank and related code
Formatting issues with Excel output from wb-fillable (closes #27)
There were two related issues with Excel output:
- When fields had blank strings as their description in WB_FIELDS_ORDERED_WITH_DESCRIPTION, wb-fillable output a spreadsheet where those values were missing, so (for example) the description for title spanned the columns for field_metadata_title, id, parent_id, and other surrounding columns
- Description text for the final column went off the edge of the page because it was being centered within multiple cells
These were both fixed by changing 'center_across': True (which centers text within all the blank cells around a given cell) to 'align': 'center' (which centers within a single cell).
While troubleshooting, I also swapped in the variable BLANK_DESCRIPTION for '' in default_specs, so if we want to in the future, we can put something like "---" instead of blank space for fields with no descriptions. (This solved the first formatting issue but not the second.)
Miscellaneous small fixes from open issues
- Change field_linked_agent_ROLE to field_linked_agent_RELATOR (closes #24)
- Add ability to count PDF pages and fill to field_extent (closes #23)
- Change --filefolder flag to --files (closes #25)
- Move logic for constructing output file names into extract_file (this should close #15 unless there's something more we want to do there)
- Get rid of some print statements that duplicate info now given in command line help text