News:

Accounts with zero posts and zero activity during the last months will be deleted periodically to fight SPAM!

Main Menu

How can I change the location of .save file(autosave)?

Started by photon3108, February 01, 2010, 04:06:33 AM

Previous topic - Next topic

photon3108

I like autosave because it saved me many times from testing new nightly build of CodeBlocks.

But it makes the source's list longer, I think that I should put all .save files in the "../save_folder".

Does anyone know how to do that?

Thanks.

MortenMacFly

Quote from: photon3108 on February 01, 2010, 04:06:33 AM
Does anyone know how to do that?
As this won't work if you have several files with the same name in a project (just in different directories) it's very unlikely that this will be implemented. However, you can adopt the AutoSave plugin yourself and just add a "../save_folder" in front of the save command.
Search for:
if(::wxFileExists(filename) && ::wxCopyFile(filename, temp))
...and adjust as needed.
However, you need to ensure the target path exists.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]

TerryP

One idea would be implementing some form of file name mangling based on variables, so it's possible to use such a folder for the saves without file name collisions; although ofc that would ruin any 8.3 limits you might need, but that's not likely a concern.
Just Another Computer Geek

MortenMacFly

Quote from: TerryP on February 01, 2010, 10:47:38 PM
One idea would be implementing some form of file name mangling based on variables,
You can also just leave it as it is (which won't conflict) and use a file manager that allows to hide file names with specific extensions. That's how I do it.
Compiler logging: Settings->Compiler & Debugger->tab "Other"->Compiler logging="Full command line"
C::B Manual: [url="https://www.codeblocks.org/docs/main_codeblocks_en.html"]https://www.codeblocks.org/docs/main_codeblocks_en.html[/url]
C::B FAQ: [url="https://wiki.codeblocks.org/index.php?title=FAQ"]https://wiki.codeblocks.org/index.php?title=FAQ[/url]