#! /usr/bin/env python # -*- coding: utf-8 -*- # vim:fenc=utf-8 # # Copyright © 2024 StrayWarrior import json gh_videos = { # meili "gh_a7c21403c493": 13586800, "gh_e0ca8ba4ed91": 13586800, "gh_859aafbcda3d": 20463342, "gh_1014734791e0": 13586800, "gh_7e33fbba4398": 13586800, "gh_aed71f26e7e6": 13586800, "gh_c783350a9660": 13586800, "gh_b2b4d5aa6b49": 13586800, "gh_9a5351c164b4": 13586800, "gh_ff16c412ab97": 20463342, "gh_1b8bfb5c4ffd": 13586800, "gh_98624814f69a": 13586800, "gh_143743361496": 13586800, "gh_7f062810b4e7": 20463342, "gh_2caed26a859c": 13586800, "gh_1014734791e0": 13586800, "gh_eeec7c2e28a5": 13586800, } all_layer_video = { # laolaifu "gh_7ad83d502e65": 20463342, "gh_c0b8f8784c39": 20463342, "gh_58393bec96ac": 20463342, "gh_0f3a6904e63e": 13586800, "gh_f4b6411dc2bb": 13586800, "gh_de67bb330fb4": 20463342, "gh_1d224e04ef3a": 20463342, "gh_97e34f88b026": 20463342, "gh_e93128efc902": 20463342, "gh_e58851b7aead": 20463342, "gh_7e7db0dc9000": 20463342, "gh_531e2204df56": 20463342, "gh_5346f126194c": 20463342, "gh_7bcb1838784c": 20463342, "gh_5f36052d6818": 20463342, "gh_6df25cec9a88": 20463342, "gh_dee6f3c0e4cf": 20463342, "gh_c8b3ff171430": 20463342, "gh_1d1459987637": 20463342, "gh_628a9ec35910": 20463342, "gh_09e3c52ef7af": 20463342, # hx "gh_580589404a08": 20463342, # hc "gh_505269831752": 20463342, # wxm "gh_95ccbf704326": 20463342, "gh_c53dc9e09fc5": 20463342, "gh_1f16bc6ac60d": 20463342, "gh_4f47d12bbe04": 20463342, "gh_87c4b8ae885e": 20463342, "gh_8c6af276df98": 20463342, "gh_dea0f9b817c6": 20463342, "gh_81d376beae2b": 20463342, } gh_videos.update(all_layer_video) config_map = {} for gh_id in gh_videos: video_id = gh_videos[gh_id] config_map[gh_id] = { "3rd-party-explore2": [ { "position": 1, "video_id": video_id } ], "3rd-party-base": [ { "position": 1, "video_id": video_id } ], } if gh_id in all_layer_video: config_map[gh_id]['3rd-party-explore1'] = [ { "position": 1, "video_id": video_id } ] print(json.dumps(config_map, indent=2))