Version: 2.4.0 (using KDE 4.5.5)
When I want to use the "organize files" function, my file is deleted.
Steps to Reproduce:
Right click on a file, a album, an artist, etc. in the collection, then choose "organize file". When the organize files dialog appears, choose your destination and confirm.
Your file(s) is (are) deleted.
"Organize files" function should move file(s) to the right destination.
Edit : In "organize files" dialog, insert "disc number". The function deletes the file if "disc number" tag (in the file) is not define.
Everything works Ok in my case. Can't reproduce It. What was I doing:
1. Selected album in collection.
2. Clicked "Organize files"
3. Chose destination to copy files.
4. Amarok asked to remove successfully copied files. Agreed.
5. Copying process finished smooth. Tracks copied to their new places. Old files removed. (only successfully copied)
What am I doing wrong?
Could you show exact steps what did you do. What scheme was used. Any strange messages during the process? Is anything interesting in debug log (amarok -d --nofork)?
Yes you're right. To reproduce the bug, you have to insert "%discnumber" in the path, but, in your file, the "discnumber" tag shouldn't be set.
In Amarok 2.3.2, the tag "discnumber" was ignored and no folder was created. The file was moved correctly. (Something like this : "Collection/%artist/%disc/%discnumber/%title.ogg" -> "Collection/Artist/Disc/Title.ogg" if %discnumber is not define.)
In Amarok 2.4, the file is deleted in the same case. But if I don't insert "%discnumber" in the path, all is right.
Yep, files really gone.
Author: Sergey Ivanov <firstname.lastname@example.org>
Date: Sun Jan 16 23:45:19 2011 +0300
Fixed issue with Organize collection, which prevent to removeing newly copied tracks.
diff --git a/ChangeLog b/ChangeLog
index 7736b92..a40b3f9 100644
@@ -13,6 +13,8 @@ VERSION 2.4.1
<email@example.com>. (BR 248690)
+ * Fixed issue with Organize collection, which prevent to removeing newly copied tracks.
+ (BR 263301)
* Fixed wrong "Configure amarok" action position in tray icon popup menu. (BR 263330)
* Fixed minor inconsistency in the Collection view. Patch by
Bhargav Mangipudi <firstname.lastname@example.org>. (BR 260973)
diff --git a/src/dialogs/TrackOrganizer.cpp b/src/dialogs/TrackOrganizer.cpp
index 349e7de..b73a7fc 100644
@@ -104,7 +104,8 @@ QString TrackOrganizer::buildDestination(const QString& format, const Meta::Trac
if( !result.startsWith( '/' ) )
result.prepend( "/" );
- return result.replace( QRegExp( "/\\.*" ), "/" );
+ QFileInfo path( result ); // Used to polish path string. (e.g. remove '//')
+ return path.absoluteFilePath();
QString TrackOrganizer::cleanPath( const QString& component ) const