Bug 447795 - option "use for playlist and folder names" in FileName Format string replacement breaks rename folder
Summary: option "use for playlist and folder names" in FileName Format string replacem...
Status: RESOLVED FIXED
Alias: None
Product: kid3
Classification: Applications
Component: general (show other bugs)
Version: 3.9.x
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: Urs Fleisch
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2022-01-01 20:55 UTC by Reuben
Modified: 2022-01-03 10:40 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments
attachment-1925-0.html (1.12 KB, text/html)
2022-01-02 11:54 UTC, Reuben
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Reuben 2022-01-01 20:55:15 UTC
SUMMARY
***
option "use for playlist and folder names" in FileName Format string replacement breaks rename folder functionality
***


STEPS TO REPRODUCE
1. set option "use for playlist and folder names" in FileName Format string replacement (it is by ddefault now it seems)
2. check there is string replacement "/" to "-"
3. try to rename folder with option %{artist}/%y - %{album}
OBSERVED RESULT
folder is renamed to %{artist}-%y - %{album}

EXPECTED RESULT
folder is renamed to %{artist}/%y - %{album}
replacement should apply inside the tokens, not to the whole string.

SOFTWARE/OS VERSIONS
Version 3.9.0
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 

KDE Frameworks Version: 
KDE Frameworks 
Version 5.89.0
Qt Version: 
Version 5.15.2 (built against 5.15.2)
ADDITIONAL INFORMATION
Comment 1 Urs Fleisch 2022-01-02 09:28:36 UTC
Git commit 3e734fd970a5fd26b61d1dd29b87a5308d0e51c5 by Urs Fleisch.
Committed on 02/01/2022 at 08:58.
Pushed by ufleisch into branch 'master'.

Fix folder renaming when filename format is used

When the option "Filename Format/Use for playlist and folder names" is
activated and the corresponding "String replacement" replaces the '/'
character, it is no longer possible, to rename a folder to multiple
path components (e.g. using the "%{artist}/%{"["year"] "}%{album}"
format in "Tools/Rename Folder").

Now the format is applied separately for each path component and
the '/' characters are preserved.

M  +14   -2    src/core/model/dirrenamer.cpp

https://invent.kde.org/multimedia/kid3/commit/3e734fd970a5fd26b61d1dd29b87a5308d0e51c5
Comment 2 Urs Fleisch 2022-01-02 09:31:16 UTC
Thank you very much for reporting this bug. I have fixed it in version git20220102, which can be found in https://sourceforge.net/projects/kid3/files/kid3/development/. Could you please test if it works for you?
Comment 3 Reuben 2022-01-02 11:54:42 UTC
Created attachment 145047 [details]
attachment-1925-0.html

Thanks a lot Urs, I'll check this as soon as possible
Reuben

On Sun, Jan 2, 2022 at 11:31 AM Urs Fleisch <bugzilla_noreply@kde.org>
wrote:

> https://bugs.kde.org/show_bug.cgi?id=447795
>
> --- Comment #2 from Urs Fleisch <ufleisch@users.sourceforge.net> ---
> Thank you very much for reporting this bug. I have fixed it in version
> git20220102, which can be found in
> https://sourceforge.net/projects/kid3/files/kid3/development/. Could you
> please
> test if it works for you?
>
> --
> You are receiving this mail because:
> You reported the bug.
Comment 4 Reuben 2022-01-03 10:40:51 UTC
fixed in git version