Go Back   Cockos Incorporated Forums > REAPER Forums > REAPER Q&A, Tips, Tricks and Howto

Reply
 
Thread Tools Display Modes
Old 12-13-2019, 05:14 PM   #1
paat
Human being with feelings
 
Join Date: Oct 2016
Posts: 225
Default Any way for "clean current project directory" to consider project files in same dir?

Doing "Clean current project directory" shows a warning message, "files listed here are not used by the current project, but may be used in some other project."

I realize that Reaper can't know about every project / file / app that may reference some audio files. But, I'm wondering if there's a way for it to consider any project files that are in the same directory? It seems like that would be possible.

The main case is for saving new versions. If I've saved several versions but deleted tracks in the latest version, I don't want "Clean current project directory" to delete those audio files, because I may want to restore them from one of the earlier versions. But, if I later decide I'm happy with the current version and I can delete earlier versions, then I would hope "Clean current project directory" would delete those audio files that are no longer referenced in any of the projects in the current directory.

Is there any way to do that? I'm on macOS if it requires some other tool / script.
paat is offline   Reply With Quote
Old 12-13-2019, 05:20 PM   #2
foxAsteria
Human being with feelings
 
foxAsteria's Avatar
 
Join Date: Dec 2009
Location: Oblivion
Posts: 10,255
Default

There are settings in the Project Bay to retain items when deleted from the project. I think that's the default, so if that's on, you should be ok (old, unused files will still be referenced as a file in the project) unless you manually removed them from there as well.
__________________
foxyyymusic
foxAsteria is offline   Reply With Quote
Old 12-14-2019, 07:08 AM   #3
Soma Jones
Human being with feelings
 
Join Date: May 2015
Posts: 67
Default

"There are settings in the Project Bay to retain items when deleted from the project."

Thank you for this suggestion, I was hoping this would solve the problem but unless I'm mis-undertanding this, it does not help.

In fact, running "Clean Currant Project Directory" even with this setting checked removes deleted files from the project folder.

The only solution I could come up with, while still being able to use the "Clean current project directory" function is to save the new version of the project along with copies of all the audio files to a new folder.

Cakewalk "Audio Finder" used to be able to check for all project files in a particular folder and only delete audio files that weren't used by any of them. I do wish Reaper could work this way as I would rather have one project folder with all the different versions referencing only one copy of any audio file needed.
Soma Jones is offline   Reply With Quote
Old 12-14-2019, 09:08 AM   #4
foxAsteria
Human being with feelings
 
foxAsteria's Avatar
 
Join Date: Dec 2009
Location: Oblivion
Posts: 10,255
Default

I don't mean to say that the setting directly affects the cleaning action. I mean if you had never turned it off, then theoretically any later version of any project will retain references to all media since the start, even if their items have since been deleted from the arrangement.

But since Reaper project files are just plain text anyway, parsing all the projects in a directory for file references should be scriptable. I'm just saying this might not be necessary, because the Project Bay setting should ensure that file references include source media used in earlier versions of the project.
__________________
foxyyymusic
foxAsteria is offline   Reply With Quote
Old 12-14-2019, 03:12 PM   #5
Soma Jones
Human being with feelings
 
Join Date: May 2015
Posts: 67
Default

I think I understand what you're saying, FoxAsteria, and yes if that option is checked the project file saves a reference to the audio file but the audio file itself will still be deleted when running "clean current project directory" on another version of the project.
Ugh, I don't know if I'm being clear but I did test this out and this is the result I got.

Parsing and scripting and all that is way beyond me.
Soma Jones is offline   Reply With Quote
Old 12-14-2019, 08:07 PM   #6
foxAsteria
Human being with feelings
 
foxAsteria's Avatar
 
Join Date: Dec 2009
Location: Oblivion
Posts: 10,255
Default

Quote:
Originally Posted by Soma Jones View Post
if that option is checked the project file saves a reference to the audio file but the audio file itself will still be deleted when running "clean current project directory" on another version of the project.
Ugh, I don't know if I'm being clear but I did test this out and this is the result I got.
Hang on, your saying that the "clean project directory" action will delete files referenced by the project if they are not currently in use?! That's completely wrong and needs to be fixed immediately if that's the case! Please put it in bug reports with the steps to reproduce if so.
__________________
foxyyymusic
foxAsteria is offline   Reply With Quote
Old 12-14-2019, 08:23 PM   #7
karbomusic
Human being with feelings
 
karbomusic's Avatar
 
Join Date: May 2009
Posts: 29,260
Default

To fix the problem Save As > Create new directory option + copy all files option (use move all if the files are not referenced by any other project ever).

Then always do that from the get go (save the project as above at the beginning) and never combine two projects that don't share the same files. It's an organizational thing, the option in question above is trying to fix the problem after the fact instead of never getting disparate projects munged together to begin with.
__________________
Music is what feelings sound like.
karbomusic is offline   Reply With Quote
Old 12-14-2019, 08:54 PM   #8
PitchSlap
Human being with feelings
 
PitchSlap's Avatar
 
Join Date: Jan 2008
Location: Vancouver, BC
Posts: 3,793
Default

This would be a really useful option.

It's pretty standard to save multiple project revisions in the same folder, and in that case only most people would only want to delete files not in any of them.
__________________
FRs: v5 Media Explorer Requests, Global Quantization, Session View
Win10 Pro 64-bit, Reaper 6(x64), AMD 3950x, Aorus X570 Master, 64GB DDR4 3600, PowerColor Red Devil 5700XT, EVO 970 2TB, 10TB HD, Define R6
PitchSlap is offline   Reply With Quote
Old 12-15-2019, 07:01 AM   #9
Soma Jones
Human being with feelings
 
Join Date: May 2015
Posts: 67
Default

You all can just ignore everything I had to say;
I tried this again this morning (selecting "automatically retain media items...)
and it seems to be working exactly as I wanted it too:

Save a new version of the project with a new version number,
in the same folder with all the audio files and
"clean current..." does not remove files used in one project version and not the other.
Soma Jones is offline   Reply With Quote
Old 01-01-2020, 03:19 PM   #10
paat
Human being with feelings
 
Join Date: Oct 2016
Posts: 225
Default

I made a feature request for anyone who would be interested in this behavior.
paat is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -7. The time now is 04:00 PM.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.