TV_MERGE(1p)
π TV_MERGE π
okay so bestie, welcome to tv_merge β it lives in the User Contributed Perl Documentation section (1p), and it's literally the glow-up your XMLTV files have been waiting for. β¨
πΈ NAME πΈ
tv_merge β merge (combine) two XMLTV files. that's it, that's the whole vibe. π
β¨ SYNOPSIS β¨
tv_merge [-t] -i FILE -m FILE -o FILE
π¦ DESCRIPTION π¦
so what we're doing here is reading XMLTV listings from two files and merging them together. π«Ά
and no, this is not the same as tv_cat β tv_cat just joins files like a lazy group project where nobody talks to each other. tv_merge actually updates the original XMLTV file (add / replace / delete, the whole main-character arc π
) using the channels and programmes it finds in that second file.
it handles multiple channels like a boss π, and it will insert any new programmes and delete any overlapping ones. lowkey obsessed with how thorough that is.
IMPORTANT π¨ the input files must be pre-sorted into datetime within channel order, and you do that with the--by-channeloption ontv_sort:
tv_sort --by-channel --output FILE FILE
all programmes must have start and stop times, no exceptions, fr fr. β°
(also, quick note bestie: programmes in the merged-in file replace any in the master file β i.e. data are not updated within programmes. so don't come for me when the insides of a programme don't get touched. π)
this program uses XML::TreePP, which doesn't write <DOCTYPE> definitions in the output file. so if you need to add a suitable <DOCTYPE> tag, use the optional -t parameter:
tv_merge -t -i FILE -m FILE -o FILE
π EXAMPLE π
say you wanna merge all channels/programmes in newadditions.xml into master.xml, and write the output to newmaster.xml with a DOCTYPE tag. iconic. do this:
tv_merge -t -i master.xml -m newadditions.xml -o newmaster.xml
π SEE ALSO π
π AUTHOR π
Copyright Geoff Westcott, February 2013.
this code is distributed under the GNU General Public License v2 (GPLv2). slay, legally. π
and that's the tea, bestie β go merge those files. this page was served fresh by perl v5.40.1 on 2025-04-19 (the TV_MERGE(1p) energy we all know and love). mwah. ππ
π¦ where this page comes from
- debian trixie: xmltv-util 1.4.0-1 Β· GPL-2.0-only
- ubuntu resolute: xmltv-util 1.4.0-1 Β· GPL-2.0-only
- ubuntu stonking: xmltv-util 1.4.0-1 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms