xmltv
XMLTV for electronic program guide (EPG) parser and generator using serde.
Features
- Flatten some elements like
<new/>to be a boolean in order to avoid boilerplate - CLI available to perform some operations
Usage
Library
use FromStr;
use from_str;
use to_string_with_root;
use *;
To serialize big files, you can look into tests/from_files.rs::test_programmes_from_files.
It reads programmes one by one without loading everything in RAM.
Command line interface (CLI)
Install it with cargo install xmltv or with the binaries.
-c <CHANNEL LIST>or--channels=<CHANNEL LIST>: channels you want to keep, ie:-c tf1,m6,Arte. You can also check them with the TUI using-c ?--cleanse <ITEM LIST>: items you want to remove form the XMLTV file. I made this option because, in XMLTV file there are a lot of data and we don't need all of them and we may want to reduce the size of the file. Available items are:credits: remove all credits. If you want to remove some of them, use:directorsactorswritersadaptersproducerscomposerseditorspresenterscommentatorsguests
categoriesnewcountrieskeywordssub-titleslanguagesvideosaudiossubtitleslast-chancesdescriptionsdatesorigin-languageslengthpremierespreviously-shownsratingsstar-ratingsreviewsimagesepisode-numsiconsurls
-d NUMBERor--days NUMBER: number of days in the EPG to keep (from today)-l <FILE>or--load <FILE>: load configuration from a JSON file-m <FILE>or--merge <FILE>: merge another XMLTV file (can be used multiple times to merge several files)-s <QUERY>or--search <QUERY>: search programmes by title (case-insensitive)-t <TZ>or--timezone <TZ>: output timezone for programme times. Values:utc(default),local(system timezone), or offset like+0100-f <FORMAT>or--format <FORMAT>: output format:xml(default),json,ical,atom,jsonfeed--epg: display the EPG in a terminal UI
Roadmap
- CLI
- configure favorites and filters?
- time slot filtering (e.g., exclude 0:00-6:00)
Ressources
XMLTV DTD is here: https://github.com/XMLTV/xmltv/blob/master/xmltv.dtd