mirror of
https://github.com/thsrite/MoviePilot-Plugins.git
synced 2026-03-27 10:05:57 +00:00
fix strm生成判断已存在
This commit is contained in:
@@ -11,7 +11,7 @@ MoviePilot三方插件市场:https://github.com/thsrite/MoviePilot-Plugins/
|
||||
|
||||
- [站点数据统计 1.0](docs%2FSiteStatisticNoMsg.md) (无未读消息版本)
|
||||
- [站点未读消息 1.2](docs%2FSiteUnreadMsg.md)
|
||||
- [云盘Strm生成 1.7](docs%2FCloudStrm.md)
|
||||
- [云盘Strm生成 2.0](docs%2FCloudStrm.md)
|
||||
- [Strm文件模式转换 1.0](docs%2FStrmConvert.md)
|
||||
- [清理订阅缓存 1.0](docs%2FSubscribeClear.md)
|
||||
- [添加种子下载 1.0](docs%2FDownloadTorrent.md)
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
|
||||
### 更新记录
|
||||
|
||||
- 2.0 修复重复执行的问题
|
||||
- 1.7 支持m2ts视频格式
|
||||
- 1.6 支持开启监控延迟
|
||||
- 1.5 优化异步执行
|
||||
|
||||
@@ -44,7 +44,7 @@ class CloudStrm(_PluginBase):
|
||||
# 插件图标
|
||||
plugin_icon = "https://raw.githubusercontent.com/thsrite/MoviePilot-Plugins/main/icons/create.png"
|
||||
# 插件版本
|
||||
plugin_version = "1.7"
|
||||
plugin_version = "2.0"
|
||||
# 插件作者
|
||||
plugin_author = "thsrite"
|
||||
# 作者主页
|
||||
@@ -241,8 +241,11 @@ class CloudStrm(_PluginBase):
|
||||
else:
|
||||
# 文件:nfo、图片、视频文件
|
||||
dest_file = event_path.replace(source_dir, dest_dir)
|
||||
if Path(dest_file).exists():
|
||||
logger.debug(f"目标文件 {dest_file} 已存在")
|
||||
return
|
||||
|
||||
# 目标文件夹不存在则创建
|
||||
# 目标文件夹不存在则创建
|
||||
if not Path(dest_file).parent.exists():
|
||||
logger.info(f"创建目标文件夹 {Path(dest_file).parent}")
|
||||
os.makedirs(Path(dest_file).parent)
|
||||
@@ -316,6 +319,9 @@ class CloudStrm(_PluginBase):
|
||||
logger.info(f"处理源文件::: {source_file}")
|
||||
|
||||
dest_file = os.path.join(dest_dir, os.path.relpath(source_file, source_dir))
|
||||
if Path(dest_file).exists():
|
||||
logger.debug(f"目标文件 {dest_file} 已存在")
|
||||
return
|
||||
logger.info(f"开始生成目标文件::: {dest_file}")
|
||||
|
||||
# 创建目标目录中缺少的文件夹
|
||||
|
||||
Reference in New Issue
Block a user