TheAcharya / MarkersExtractor

Extract Markers from Final Cut Pro FCPXML
MIT License
38 stars 2 forks source link

`--label` CLI argument should take short-form label IDs #15

Closed orchetect closed 1 year ago

orchetect commented 1 year ago

Currently the --label CLI argument requires using the actual string of the CSV field names which is a bit obtuse.

markers-extractor-cli --label 'Marker Name' --label 'Role & Subrole' file.fcpxml ./output

It is more idiomatic for CLI utilities to use identifiers without spaces or special characters.

markers-extractor-cli --label id --label role file.fcpxml ./output

Using IDs for these labels will help if additional export formats are added (.tsv file, Excel spreadsheet, or any other potential format) which may use different field names for exporting metadata. This way the IDs remain stable regardless of potential format used.

Additionally, --help-labels CLI flag can be removed as it's not really necessary. All the label IDs can be listed inline with the main CLI help block.

OPTIONS:
< ... >
--label <id,name,type,checked,status,notes,position,clipName,clipDuration,role,eventName,projectName,libraryName,iconImage,imageFileName>
                          Label to overlay on thumb images. This argument can
                          be supplied more than once to apply multiple labels.
< ... >
orchetect commented 1 year ago

All points above have been implemented on the refactors branch.