mirror of
https://github.com/iptv-org/epg
synced 2025-12-17 10:56:57 -05:00
Update scripts
This commit is contained in:
18
scripts/commands/api/load.ts
Normal file
18
scripts/commands/api/load.ts
Normal file
@@ -0,0 +1,18 @@
|
||||
import { Logger } from '@freearhey/core'
|
||||
import { ApiClient } from '../../core'
|
||||
|
||||
async function main() {
|
||||
const logger = new Logger()
|
||||
const client = new ApiClient({ logger })
|
||||
|
||||
const requests = [
|
||||
client.download('channels.json'),
|
||||
client.download('countries.json'),
|
||||
client.download('regions.json'),
|
||||
client.download('subdivisions.json')
|
||||
]
|
||||
|
||||
await Promise.all(requests)
|
||||
}
|
||||
|
||||
main()
|
||||
Reference in New Issue
Block a user