Skip to content

Commit

Permalink
v3.4.4 修复重命名时路径嵌套的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
LuckyPuppy514 committed Jun 4, 2024
1 parent ce4a036 commit b10864b
Show file tree
Hide file tree
Showing 6 changed files with 20 additions and 5 deletions.
4 changes: 4 additions & 0 deletions changelog.en_US.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@

# Change Logs

## v3.4.4 2024-06-04

👻 Fix the issue of nested path while renaming

## v3.4.3 2024-02-20

🚀 Optimize radarr title matching logic
Expand Down
4 changes: 4 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,10 @@

# 变更日志

## v3.4.4 2024-06-04

👻 修复重命名时路径嵌套的问题

## v3.4.3 2024-02-20

🚀 优化 Radarr 标题匹配逻辑
Expand Down
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
<!-- 项目信息 -->
<groupId>com.lckp</groupId>
<artifactId>jproxy</artifactId>
<version>3.4.3</version>
<version>3.4.4</version>
<name>JProxy</name>
<description>介于 Sonarr/Radarr 和 Jackett/Prowlarr 之间的代理,主要用于优化查询和提升识别率</description>
<!-- 依赖版本 -->
Expand Down
5 changes: 3 additions & 2 deletions src/main/java/com/lckp/jproxy/task/RadarrRenameTask.java
Original file line number Diff line number Diff line change
Expand Up @@ -122,8 +122,9 @@ public synchronized void run() {
if (extension.matches(Common.SUBTITLE_EXTENSION_REGEX)) {
newFileName = newFileName + "." + subtitleNo++;
}
newFileName = newFileName + " "
+ sourceTitle.substring(sourceTitle.indexOf("["))
int index = sourceTitle.indexOf(" [");
newFileName = newFileName
+ (index > -1 ? sourceTitle.substring(index) : "")
+ extension;
}
String newFilePath;
Expand Down
5 changes: 3 additions & 2 deletions src/main/java/com/lckp/jproxy/task/SonarrRenameTask.java
Original file line number Diff line number Diff line change
Expand Up @@ -149,8 +149,9 @@ public synchronized void run() {
if (extension.matches(Common.SUBTITLE_EXTENSION_REGEX)) {
newFileName = newFileName + "." + subtitleNo++;
}
newFileName = newFileName + " "
+ sourceTitle.substring(sourceTitle.indexOf("["))
int index = sourceTitle.indexOf(" [");
newFileName = newFileName
+ (index > -1 ? sourceTitle.substring(index) : "")
+ extension;
}
}
Expand Down
5 changes: 5 additions & 0 deletions src/main/resources/database/changelog/v3.4.4.sql
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
--liquibase formatted sql logicalFilePath:/database/changelog/v3.4.4.sql
--changeset LuckyPuppy514:1
--comment: 更新净标题正则表达式
UPDATE system_config SET value='(`|,|~|!|@|#|%|&|_|=|''|"|:|<|>|-|—|·|,|~|、|。|‘|’|“|”|?|!|:|(|)|【|】|《|》|♀|/)' WHERE id=16;
--rollback UPDATE system_config SET value='(`|,|~|!|@|#|%|&|_|=|''|"|:|<|>|-|—|·|,|~|、|。|‘|’|“|”|?|!|:|(|)|【|】|《|》|♀)' WHERE id=16;

0 comments on commit b10864b

Please sign in to comment.