From c2f9ff6df56fefc7d6ce0bebcfe17c5fc70e4d45 Mon Sep 17 00:00:00 2001 From: freearhey <7253922+freearhey@users.noreply.github.com> Date: Fri, 1 Dec 2023 01:08:46 +0300 Subject: [PATCH] Update tvgids.nl --- sites/tvgids.nl/readme.md | 21 +++++++++++++ sites/tvgids.nl/tvgids.nl.channels.xml | 43 +++++++++++++------------- sites/tvgids.nl/tvgids.nl.config.js | 4 +-- sites/tvgids.nl/tvgids.nl.test.js | 3 -- 4 files changed, 44 insertions(+), 27 deletions(-) create mode 100644 sites/tvgids.nl/readme.md diff --git a/sites/tvgids.nl/readme.md b/sites/tvgids.nl/readme.md new file mode 100644 index 00000000..5a4b4926 --- /dev/null +++ b/sites/tvgids.nl/readme.md @@ -0,0 +1,21 @@ +# tvgids.nl + +https://www.tvgids.nl/gids/ + +### Download the guide + +```sh +npm run grab -- --site=tvgids.nl +``` + +### Update channel list + +```sh +npm run channels:parse -- --config=./sites/tvgids.nl/tvgids.nl.config.js --output=./sites/tvgids.nl/tvgids.nl.channels.xml +``` + +### Test + +```sh +npm test -- tvgids.nl +``` diff --git a/sites/tvgids.nl/tvgids.nl.channels.xml b/sites/tvgids.nl/tvgids.nl.channels.xml index 1e86788d..10a46fb6 100644 --- a/sites/tvgids.nl/tvgids.nl.channels.xml +++ b/sites/tvgids.nl/tvgids.nl.channels.xml @@ -1,18 +1,22 @@ - - - - - - - - - - - - 24Kitchen + 3Sat + 24Kitchen Al Jazeera Engels Animal Planet ARTE @@ -21,24 +25,21 @@ BBC First BBC World Beleef KPN - Boomerang BVN - Canvas + VRT Canvas Cartoon Network CBS Reality CNBC CNN - Comedy Central Extra Comedy Central Crime + Investigation Discovery Disney Channel Disney XD - Eén ESPN 2 ESPN 3 ESPN 4 - ESPN + ESPN 1 Eurosport 1 Eurosport 2 Extreme Sports Channel @@ -47,7 +48,6 @@ Film1 Family Film 1 Premiere Filmbox.nl - Fox HISTORY INPLUS Investigation Discovery @@ -61,7 +61,6 @@ Nat Geo Wild NDR Fernsehen NET 5 - NH Nickelodeon Nick Jr. NPO 1 @@ -75,7 +74,7 @@ Omroep Gelderland Omroep Zeeland Omrop Fryslân - Ons + ONS OUTtv Pebble TV Play4 @@ -85,7 +84,7 @@ RTL 5 RTL 7 RTL 8 - Rtl crime + RTL Crime RTL Lounge RTL Telekids RTL Z @@ -100,8 +99,8 @@ RTBF La 2 TLC TRT World - TV 538 TV5MONDE + TV 538 TV E TV Noord Oranje TV diff --git a/sites/tvgids.nl/tvgids.nl.config.js b/sites/tvgids.nl/tvgids.nl.config.js index b0524358..05cfd85a 100644 --- a/sites/tvgids.nl/tvgids.nl.config.js +++ b/sites/tvgids.nl/tvgids.nl.config.js @@ -7,7 +7,7 @@ module.exports = { days: 2, url: function ({ date, channel }) { const path = - DateTime.now().day === DateTime.fromMillis(date.valueOf()).day + DateTime.utc().day === DateTime.fromMillis(date.valueOf()).day ? '' : `${date.format('DD-MM-YYYY')}/` @@ -48,7 +48,7 @@ module.exports = { const $ = cheerio.load(data) const channels = [] - $('#channel-container > div').each((i, el) => { + $('.guide__channel-logo-container').each((i, el) => { channels.push({ site_id: $(el).find('a').attr('id'), name: $(el).find('img').attr('title'), diff --git a/sites/tvgids.nl/tvgids.nl.test.js b/sites/tvgids.nl/tvgids.nl.test.js index 839976ac..c837157c 100644 --- a/sites/tvgids.nl/tvgids.nl.test.js +++ b/sites/tvgids.nl/tvgids.nl.test.js @@ -1,6 +1,3 @@ -// npm run channels:parse -- --config=./sites/tvgids.nl/tvgids.nl.config.js --output=./sites/tvgids.nl/tvgids.nl.channels.xml -// npm run grab -- --site=tvgids.nl - const { parser, url } = require('./tvgids.nl.config.js') const fs = require('fs') const path = require('path')