geopython / geopython/pygeometa

Batch processing of MCF files from a user-specified location

Open
#63 4 comments 0 reactions 0 assignees View on GitHub
enhancement help wanted
Dominant language
Python
Stars
127
Forks
52
Avg merge
3d 8h
Merged PRs (30d)
1

Description

Feature request for the capability to launch pygeometa and process multiple MCF files located in a user-specified directory with a single command.

This 'batch mode' could be invoked directly from pygeometa with the ```--batch``` argument. If ```--batch``` is specified, then pygeometa is ran for every mcf files in the directory specified with ```--mfc=``` and all the outputs files are named the same as input files but end with .xml and are saved in the directory specified by ```--output```. Other pygeometa arguments such as ```--schema=``` are applied to all MCF files processed in batch.

An initial version of this batch mode can simply loop on all mcf files and generate the corresponding xml files. The batch mode should skip base_mcf mcf files, which can't be processed on their own.

Future versions could:
* Recursively look in the ```--mfc=``` folder to process .mcf files located in subfolders as well and output the same directory structure to ```--output=```
* Provide a log with warnings, errors and outputs. The log location and named could be specified by the ```--log=``` argument
* The batch mode could also look in the output directly if a corresponding xml exists and skip running if the input mcf file has not change since last time the batch mode was ran. The last time the batch mode was ran could be specified in the log file found at the ```--log=``` location

Thoughts / comments?

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.