Ai-desu-2333 / Pixiv2Billfish

Pixiv Illustrator tags and descriptions imported into Billfish / Pixiv插画Tag和描述导入Billfish
GNU General Public License v3.0
52 stars 4 forks source link

不同名称格式的图片的pid匹配 #7

Open ternurarl opened 9 months ago

ternurarl commented 9 months ago

我在手机版pixiv下载的图片的格式多为illust_xxxxxx_yyyyddmm_xxxx.jpg Screenshot_2024-01-29-14-55-18-325_com miui galle

ternurarl commented 9 months ago

刚开始运行时发现跳过了太多 image

LSP0123 commented 9 months ago

不同软件下的不一样,你需要在软件里将下载命名规则修改为PID.jpg/png 或者手动修改文件名为pid.jpg/png,自己写一个批处理也可以 Advanced Renamer这个软件可以帮到你

Ai-desu-2333 commented 6 months ago

可以在Pixiv2Billfish.py中,搜索elif "_" in name:找到此处代码,

        elif "_" in name:
            pid = name.split("_")[0]

将其改成下面这个样子,来适配illust_pid_xxx的情况

        elif "_" in name:
            pid = name.split("_")[0]
            if pid == "illust":
                pid = name.split("_", 2)[1]