From f1d857b5ab44b35cf049981a2597b9a9610eae94 Mon Sep 17 00:00:00 2001 From: metamuffin Date: Sun, 15 Jun 2025 12:32:44 +0200 Subject: add nicovideo support --- scripts/ytdlp_flatten.ts | 2 ++ 1 file changed, 2 insertions(+) (limited to 'scripts/ytdlp_flatten.ts') diff --git a/scripts/ytdlp_flatten.ts b/scripts/ytdlp_flatten.ts index 499233d..896e5a2 100644 --- a/scripts/ytdlp_flatten.ts +++ b/scripts/ytdlp_flatten.ts @@ -6,11 +6,13 @@ let config: Config = {} as unknown as Config const supported = [ "youtube-channel", "bilibili-channel", + "niconico-channel", ] function key_to_url(key: string): [string, string] { const [kind, id] = key.split(":", 2) if (kind == "youtube-channel") return ["youtube", `https://youtube.com/channel/${id}`] if (kind == "bilibili-channel") return ["bilibili", `https://space.bilibili.com/${id}/upload/video`] + if (kind == "niconico-channel") return ["niconico", `https://www.nicovideo.jp/user/${id}`] throw new Error("unknown kind"); } function key_to_infokey(key: string): string { -- cgit v1.2.3-70-g09d2