amtoaer / bili-sync

由 Rust & Tokio 驱动的哔哩哔哩同步工具
https://bili-sync.allwens.work
MIT License
605 stars 44 forks source link

请问为什么docker自动生成的config.json格式,与官网上的配置文件的格式不一样? #168

Closed FenchD closed 3 months ago

FenchD commented 3 months ago

docker生成的是纯json格式,参数没有官网上写的那么多。特别是:对应的video_name和page_name这些参数,抓取视频成功,但是文件名是乱码。

官网上的配置说明: 当前版本的默认示例文件如下:

video_name = "{{title}}"
page_name = "{{bvid}}"
interval = 1200
upper_path = "/Users/amtoaer/Library/Application Support/bili-sync/upper_face"
nfo_time_type = "favtime"

[credential]
sessdata = ""
bili_jct = ""
buvid3 = ""
dedeuserid = ""
ac_time_value = ""

[filter_option]
video_max_quality = "Quality8k"
video_min_quality = "Quality360p"
audio_max_quality = "QualityHiRES"
audio_min_quality = "Quality64k"
codecs = [
    "AV1",
    "HEV",
    "AVC",
]
no_dolby_video = false
no_dolby_audio = false
no_hdr = false
no_hires = false

[danmaku_option]
duration = 15.0
font = "黑体"
font_size = 25
width_ratio = 1.2
horizontal_gap = 20.0
lane_size = 32
float_percentage = 0.5
bottom_percentage = 0.3
opacity = 76
bold = true
outline = 0.8
time_offset = 0.0

[favorite_list]

[collection_list]

[watch_later]
enabled = false
path = ""

我按上面说明编写的config.json如下:

{
    "sessdata": "xxx",
    "bili_jct": "xxx",
    "buvid3": "xxx",
    "dedeuserid": "xxx",
    "ac_time_value": "xxx",
    "interval": 1200,
    "path_mapper": {
        "xxx": "/Videos/Bilibilis/"
    },
    "video_name": "{{title}}",
    "page_name": "{{bvid}}",
    "subtitle": {
        "font_name": "微软雅黑,黑体",
        "font_size": 40.0,
        "alpha": 0.8,
        "fly_time": 5.0,
        "static_time": 10.0
    },
    "stream": {
        "video_max_quality": 127,
        "audio_max_quality": 30280,
        "video_min_quality": 16,
        "audio_min_quality": 30216,
        "codecs": [
            "av01",
            "avc",
            "hev"
        ],
        "no_dolby_video": false,
        "no_dolby_audio": false,
        "no_hdr": false,
        "no_hires": false
    },
    "paginated_video": true
}

谢谢

HWWHEN commented 3 months ago

这是旧版本的,注意docker镜像名称,旧版本是bili-sync,新版本是bili-sync-rs