mirror of
https://github.com/iptv-org/epg.git
synced 2025-05-10 09:00:07 -04:00
Merge pull request #179 from iptv-org/add-ignore-option
Add ignore option
This commit is contained in:
commit
d552efc5c4
4 changed files with 7 additions and 5 deletions
2
.github/workflows/auto-update.yml
vendored
2
.github/workflows/auto-update.yml
vendored
|
@ -31,7 +31,7 @@ jobs:
|
|||
run: npm install
|
||||
- name: Create Matrix
|
||||
id: set-matrix
|
||||
run: node scripts/create-matrix.js --exclude=sites/tvprofil.com/*,sites/znbc.co.zm/*
|
||||
run: node scripts/create-matrix.js
|
||||
grab:
|
||||
runs-on: ubuntu-latest
|
||||
needs: create-matrix
|
||||
|
|
|
@ -1,5 +1,6 @@
|
|||
const { Command } = require('commander')
|
||||
const file = require('./file')
|
||||
const path = require('path')
|
||||
|
||||
const program = new Command()
|
||||
program
|
||||
|
@ -16,6 +17,9 @@ file.list('sites/*/*.channels.xml', options.include, options.exclude).then(files
|
|||
|
||||
files.forEach(filename => {
|
||||
const [_, site, country] = filename.match(/sites\/.*\/(.*)_(.*)\.channels\.xml/i)
|
||||
const config = require(path.resolve(`./sites/${site}/${site}.config.js`))
|
||||
|
||||
if (config.ignore) return
|
||||
|
||||
matrix.guide.push({ site, country })
|
||||
})
|
||||
|
|
|
@ -1,10 +1,9 @@
|
|||
// BUG: server is not stable
|
||||
|
||||
const cheerio = require('cheerio')
|
||||
const dayjs = require('dayjs')
|
||||
|
||||
module.exports = {
|
||||
site: 'tvprofil.com',
|
||||
ignore: true, // NOTE: server is not stable
|
||||
request: {
|
||||
headers: {
|
||||
'x-requested-with': 'XMLHttpRequest'
|
||||
|
|
|
@ -1,5 +1,3 @@
|
|||
// BUG: site is down
|
||||
|
||||
const jsdom = require('jsdom')
|
||||
const { JSDOM } = jsdom
|
||||
const dayjs = require('dayjs')
|
||||
|
@ -14,6 +12,7 @@ dayjs.extend(customParseFormat)
|
|||
|
||||
module.exports = {
|
||||
site: 'znbc.co.zm',
|
||||
ignore: true, // NOTE: site is down
|
||||
url({ channel }) {
|
||||
return `https://www.znbc.co.zm/${channel.site_id}/`
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue