OCR-D / zenhub

Repo for developing zenhub integration
Apache License 2.0
0 stars 0 forks source link

Consistent usage pattern for CLI options --mets/--mets-basename/--working-dir #26

Open kba opened 2 years ago

kba commented 2 years ago

Current situation

The three options -M/--mets, -m/--mets-basename and -w/--working-dir (processors) / -d/--directory (ocrd workspace) are inter-connected and they can clash to cause ambiguous behavior when combined.

For example, if you do ocrd workspacd -d /path/to/workspace1 -m /path/to/workspace2/mets.xml -M not-mets.xml, where should we look for the METS?

How it should be

--mets-basename should be deprecated in ocrd workspace, it can be simulated with a combination of --mets and --directory.

--working-dir should be properly taken into account for processor calls.

The resolving logic of processors and ocrd workspace should ideally use the same code for consistency

Steps

paulpestov commented 2 years ago

Is it possible to provide an example for ambiguous behavior?

mweidling commented 2 years ago

I think this epics lacks a step when deprecating --mets-basename: We should update this parameter's docs to make clear how its behaviour can be achieved by using the other two params. Or is this already implicit?

kba commented 2 years ago

Is it possible to provide an example for ambiguous behavior?

For example, if you do ocrd workspacd -d /path/to/workspace1 -m /path/to/workspace2/mets.xml -M not-mets.xml, where should we look for the METS?