diff --git a/.gitignore b/.gitignore index 94d0fac..24b990d 100644 --- a/.gitignore +++ b/.gitignore @@ -20,5 +20,6 @@ # Go workspace file go.work go.work.sum + cookies.json .DS_Store \ No newline at end of file diff --git a/download_plugin/info.go b/download_plugin/info.go index c20cf3f..c98c73b 100644 --- a/download_plugin/info.go +++ b/download_plugin/info.go @@ -9,6 +9,7 @@ import ( "net/url" "os" "strings" + "time" ) func getLiveRoomPublicInfo(roomId, liveUuid string, Thread int) { @@ -64,6 +65,10 @@ func getLiveRoomPublicInfo(roomId, liveUuid string, Thread int) { title := result["openLiveDetailModel"].(map[string]interface{})["title"].(string) playbackUrl := result["openLiveDetailModel"].(map[string]interface{})["playbackUrl"].(string) + // 获取当前时间并格式化 + currentTime := time.Now().Format("2006-01-02 15:04:05") + title += "_" + currentTime + fmt.Println("标题:", title) fmt.Println("请求网址:", playbackUrl) M3u8Down(title, playbackUrl, Thread)