mirror of
https://github.com/iptv-org/epg
synced 2025-12-17 10:56:57 -05:00
Update streamingtvguides.com
This commit is contained in:
21
sites/streamingtvguides.com/readme.md
Normal file
21
sites/streamingtvguides.com/readme.md
Normal file
@@ -0,0 +1,21 @@
|
|||||||
|
# streamingtvguides.com
|
||||||
|
|
||||||
|
https://streamingtvguides.com/
|
||||||
|
|
||||||
|
### Download the guide
|
||||||
|
|
||||||
|
```sh
|
||||||
|
npm run grab -- --site=streamingtvguides.com
|
||||||
|
```
|
||||||
|
|
||||||
|
### Update channel list
|
||||||
|
|
||||||
|
```sh
|
||||||
|
npm run channels:parse -- --config=./sites/streamingtvguides.com/streamingtvguides.com.config.js --output=./sites/streamingtvguides.com/streamingtvguides.com.channels.xml
|
||||||
|
```
|
||||||
|
|
||||||
|
### Test
|
||||||
|
|
||||||
|
```sh
|
||||||
|
npm test -- streamingtvguides.com
|
||||||
|
```
|
||||||
File diff suppressed because it is too large
Load Diff
@@ -32,6 +32,33 @@ module.exports = {
|
|||||||
programs = _.orderBy(_.uniqBy(programs, 'start'), 'start')
|
programs = _.orderBy(_.uniqBy(programs, 'start'), 'start')
|
||||||
|
|
||||||
return programs
|
return programs
|
||||||
|
},
|
||||||
|
async channels({ country, lang }) {
|
||||||
|
const axios = require('axios')
|
||||||
|
const data = await axios
|
||||||
|
.get(`https://streamingtvguides.com/Preferences`)
|
||||||
|
.then(r => r.data)
|
||||||
|
.catch(console.log)
|
||||||
|
|
||||||
|
let channels = []
|
||||||
|
|
||||||
|
const $ = cheerio.load(data)
|
||||||
|
$('#channel-group-all > div > div').each((i, el) => {
|
||||||
|
const site_id = $(el).find('input').attr('value').replace('&', '&')
|
||||||
|
const label = $(el).text().trim()
|
||||||
|
const svgTitle = $(el).find('svg').attr('alt')
|
||||||
|
const name = (label || svgTitle || '').replace(site_id, '').trim()
|
||||||
|
|
||||||
|
if (!name || !site_id) return
|
||||||
|
|
||||||
|
channels.push({
|
||||||
|
lang: 'en',
|
||||||
|
site_id,
|
||||||
|
name
|
||||||
|
})
|
||||||
|
})
|
||||||
|
|
||||||
|
return channels
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,3 @@
|
|||||||
// npm run grab -- --site=streamingtvguides.com
|
|
||||||
|
|
||||||
const { parser, url } = require('./streamingtvguides.com.config.js')
|
const { parser, url } = require('./streamingtvguides.com.config.js')
|
||||||
const fs = require('fs')
|
const fs = require('fs')
|
||||||
const path = require('path')
|
const path = require('path')
|
||||||
|
|||||||
Reference in New Issue
Block a user