mosromgr merge¶
Merge the provided MOS files
Synopsis¶
mosromgr merge [-h] [-f [files [files ...]]] [-b bucket] [-p prefix] [-s suffix]
[-o outfile] [-i] [-n]
Description¶
- -f --files [files ...]¶
The MOS files to merge
- -b --bucket-name bucket¶
The name of the S3 bucket containing the MOS files
- -p --prefix prefix¶
The file prefix for MOS files in the S3 bucket
- -s --suffix suffix¶
The file suffix for MOS files in the S3 bucket
- -o --outfile outfile¶
Output to a file
- -i --incomplete¶
Allow an incomplete collection
- -n --non-strict¶
Downgrade MOS merge errors to warnings
- -h, --help¶
Show this help message and exit
Usage¶
Merge local files and store the result in a new file:
$ mosromgr merge -f *.mos.xml -o FINAL.xml
...
INFO:mosromgr.moscollection:Merging RunningOrderEnd 123499
INFO:mosromgr.moscollection:Completed merging 99 mos files
Writing merged running order to FINAL.xml
Merge files in an S3 bucket folder by prefix and store the result in a new file:
$ mosromgr merge -b my-bucket -p newsnight/20210101/ -o FINAL.xml
...
INFO:mosromgr.moscollection:Merging RunningOrderEnd 123499
INFO:mosromgr.moscollection:Completed merging 99 mos files
Writing merged running order to FINAL.xml
Note
Your AWS credentials must be configured to use the S3 method. See https://boto3.amazonaws.com/v1/documentation/api/latest/guide/credentials.html