Autosave & Autobackup (foo_jesus), Free salvation for your configuration, playlists and soul. |
![]() ![]() |
Autosave & Autobackup (foo_jesus), Free salvation for your configuration, playlists and soul. |
Jan 8 2009, 22:51
Post
#1
|
|
![]() Group: FB2K Moderator Posts: 2359 Joined: 30-November 07 Member No.: 49158 |
This component allows periodic automatic saving of configuration and other data in foobar2000 and keeping backup copies of the profile folder.
The save operation itself does the same as (hidden) command "File > Save Configuration", that means it saves configuration (the whole configuration subfolder), Media library database (database.*), playlists and any additional data managed by other components (for example current theme or playback statistics). Backup process stores configurable list of files and directories into a ZIP archive with file name like "autobackup.20091005-121722.zip" in user-specified folder. A ZIP archive is used to have everything in one file, as well as compress the (often large) database files a bit, using the fastest, but still significant and useful compression method. Very small files, as well as not much compressible files like archives and compressed images are not (re)compressed. Configuration is possible through the following settings, available in "Autosave & Autobackup" branch in Advanced preferences:
A message like "Autosaving... (A)" is logged to console each time, among others to avoid "bug reports" regarding random lags. One of the letters PITA at the end reveals the reason – while Playing, when Idle, after Track or Always. Note that configuration saving can be a resource intensive operation, particularly with larger libraries or playlists. It should not disturb playback, however user interface lag might occur. The subsequent backup operation is run in a detached thread with lowered priority. I've made the default settings rather conservative and according to my typical usage – each hour when foobar2000 is happily playing minimized, five minutes after everything has stopped and I'm going to do something else, then at least once a day just as a safety measure (if I haven't actually played anything and only experimented with some configuration changes, for example). Your comments and suggestions are welcome. Latest version: Autosave & Autobackup v10 [2010/09/23] Dowload links: foo_jesus-v10.zip (43 KB) foo_jesus.dll (89 KB) mirror Changelog: v10 [2010/09/23] - New: Use zlib1.dll bundled with core - the component needs foobar2000 v1.1 or newer now. - New: Don't compress .rar and .7z files (added to existing .zip, .jpg, .jpeg and .png). - New: Updated default backup item list: removed "foobar2000.cfg", added "index-data" (used e.g. by Playback Statistics v3.0+). Note: If you are upgrading from a previous version and changed the default pattern, you ought to do this manually. - Fixed: Filter . and .. pseudo-directories when backing up the whole profile folder (using * as the mask). v9 [2010/04/20] - New: Option for setting delay of the first backup after startup. - Fixed: Even lower priority for the backup thread. v8 [2010/01/03] - Fixed: Relative paths to destination directory. v7 [2010/01/02] - New: Backup ZIP files use compression. - New: Configurable backup destination directory. - Fixed: Added 30 second limit for per-track autosave to avoid main thread overload. v6 [2009/11/20] - Added a few things to ease debugging of obscure problems in other components. v5 [2009/10/05] - Fixed: Crash with empty backup filename pattern list. v4 [2009/10/04] - New: Added backup features. v0.0.3 [2009/03/21] - Fixed: Crash when autosaving after number of tracks with Preferences dialog open. v0.0.2 [2009/01/09] – New: Ability to save each time a configured number of tracks has been played. v0.0.1 [2009/01/08] – Initial release. This post has been edited by Yirkha: Sep 23 2010, 01:38 -------------------- Full-quoting makes you scroll past the same junk over and over.
|
|
|
|
Jan 8 2009, 23:16
Post
#2
|
|
|
Group: Members Posts: 43 Joined: 18-July 07 Member No.: 45428 |
Wow, I've been waiting for ages for such component. Could be very useful for people who like playing with ColumnsUI or PanelsUI. Thanks
|
|
|
|
Jan 9 2009, 01:37
Post
#3
|
|
|
troll / ban evasion Group: Banned Posts: 244 Joined: 22-April 08 Member No.: 52991 |
Thanks Yirkha for this useful component (foo_jesus...
Now for the "just a little improvement" thing Thanks again. |
|
|
|
Jan 9 2009, 03:48
Post
#4
|
|
|
Group: Members Posts: 99 Joined: 25-August 08 Member No.: 57492 |
Thanks for the great component. I am just wondering if you can add a menu item or I can create a command button to save all configurations on demand. Sometimes I know that I have made a few changes to configurations and playlists, if I don't save them I might lose them all should there be a crash.
ftc |
|
|
|
Jan 9 2009, 06:10
Post
#5
|
|
![]() Group: Members Posts: 50 Joined: 22-February 08 Member No.: 51505 |
Great improvement to foobar2000.
Really thanks for this component! BTW, there is a better name for it? Edit: typo. This post has been edited by ZeeJay: Jan 9 2009, 08:26 |
|
|
|
Jan 9 2009, 06:45
Post
#6
|
|
![]() Group: Members (Donating) Posts: 1983 Joined: 4-January 04 From: Austin, TX Member No.: 10933 |
Who else saves better than Jesus?
This post has been edited by Axon: Jan 9 2009, 06:45 |
|
|
|
Jan 9 2009, 07:32
Post
#7
|
|
|
Group: Validating Posts: 2424 Joined: 21-May 08 Member No.: 53675 |
first save yourself (File > Save Configuration), then ask Jesus
|
|
|
|
Jan 9 2009, 08:20
Post
#8
|
|
![]() Group: Members Posts: 50 Joined: 22-February 08 Member No.: 51505 |
|
|
|
|
Jan 9 2009, 12:30
Post
#9
|
|
|
Group: Members Posts: 337 Joined: 28-October 06 Member No.: 36898 |
I am just wondering if you can add a menu item or I can create a command button to save all configurations on demand. This ability actually exists already. It's not visible on the menu, but you can bind File->Save Configuration to a keyboard shortcut or to a button (the latter I've only tested in Columns UI because I am deeply lazy, but there's no reason it shouldn't work in Default as well). Anyhow, thanks for the component, Yirkha! |
|
|
|
Jan 9 2009, 18:10
Post
#10
|
|
|
Group: Members Posts: 99 Joined: 25-August 08 Member No.: 57492 |
I am just wondering if you can add a menu item or I can create a command button to save all configurations on demand. This ability actually exists already. It's not visible on the menu, but you can bind File->Save Configuration to a keyboard shortcut or to a button (the latter I've only tested in Columns UI because I am deeply lazy, but there's no reason it shouldn't work in Default as well). Anyhow, thanks for the component, Yirkha! Thanks, DocBeard. It was not obvious to me before, now I know. |
|
|
|
Jan 9 2009, 18:40
Post
#11
|
|
![]() Group: FB2K Moderator Posts: 2359 Joined: 30-November 07 Member No.: 49158 |
Saving your config, playlists & co. is nice, but it has happened to me more than once in the past to end up with a corrupt foobar2000.cfg file (because of other software running and making fb2k crash, not enough free memory which would mess up with foobar quitting, whatever). In that case, you'd better have a recent backup of that precious cfg file if you don't want to start all over again. So, would it be a good idea to automatically backup the foobar2000.cfg in the same folder ? It's the core what does the saving, this component only launches the menu command to do it, so there is no reliable control over that part.Maybe start using Windows Vista… ![]() ETA: mikusr reminded me that "Previous versions" is available only in Business, Enterprise and Ultimate SKU's. This post has been edited by Yirkha: Jan 9 2009, 19:25 -------------------- Full-quoting makes you scroll past the same junk over and over.
|
|
|
|
Jan 9 2009, 19:03
Post
#12
|
|
![]() Group: Members Posts: 119 Joined: 21-August 05 Member No.: 24044 |
Would it be possible to add an option to save every time playback of a new track starts?
|
|
|
|
Jan 9 2009, 19:29
Post
#13
|
|
![]() Group: FB2K Moderator Posts: 2359 Joined: 30-November 07 Member No.: 49158 |
I thought about that initially, then everything became time-based, so I abandoned it. I also don't like constant updates, because when something bad happens while saving, it creates much bigger problems. I guess I made it usable with rather long intervals also because I don't care about recent activity much. I was only surprised sometimes when my changes from last month were gone or so.
But oh well, you are second to ask for this, I will give it another thought. -------------------- Full-quoting makes you scroll past the same junk over and over.
|
|
|
|
Jan 9 2009, 19:46
Post
#14
|
|
|
Group: Members Posts: 55 Joined: 13-March 07 Member No.: 41449 |
praise the lord!
Thanks for a plugin that is useful. I can't tell you how many times I've had to redo things to my theme/layout, remake playlists, etc because they went into oblivion. This plugin is probably essential enough to most users that it should be a built-in feaure of foobar2000. |
|
|
|
Jan 9 2009, 21:05
Post
#15
|
|
![]() Group: FB2K Moderator Posts: 2359 Joined: 30-November 07 Member No.: 49158 |
v0.0.2 released, first post in this topic updated.
-------------------- Full-quoting makes you scroll past the same junk over and over.
|
|
|
|
Jan 10 2009, 01:02
Post
#16
|
|
|
Group: Members Posts: 253 Joined: 20-April 06 Member No.: 29815 |
Thank you Yirkha, this component kind of made my day.
|
|
|
|
Jan 10 2009, 03:51
Post
#17
|
|
|
Group: Members Posts: 55 Joined: 18-December 06 Member No.: 38804 |
What a cool name for a plugin. WWJD?
Its a great plugin, saves me the hassle of redoing all those keyboard configs. |
|
|
|
Jan 10 2009, 06:38
Post
#18
|
|
![]() Group: Members (Donating) Posts: 782 Joined: 11-April 05 From: México Member No.: 21361 |
Cool component, this should save me some work after my neighborhood's frequent pawer outages lol
-------------------- we was young an' full of beans
|
|
|
|
Jan 11 2009, 02:36
Post
#19
|
|
![]() Group: Members Posts: 380 Joined: 27-September 03 Member No.: 9041 |
Thanks Yirkha for this useful component (foo_jesus... Now for the "just a little improvement" thing Thanks again. Going further, it would be useful if the plugin could make whole config backups at set intervals, timestamped into an alternate directory (like backup\20081119\). The shadow copy functionality in Vista is very useful but not available for all. Also, best plugin description ever. -------------------- http://evilboris.sonic-cult.net/346/
Sega Saturn, Shiro! |
|
|
|
Jan 11 2009, 13:17
Post
#20
|
|
|
troll / ban evasion Group: Banned Posts: 244 Joined: 22-April 08 Member No.: 52991 |
Yes, some of us don't want to use Vista because XP is lighter and better for a HTPC.
Moderation: This point has been disputed, see the split topic here. Any backup software could automatically make those foobar.cfg backups, but it would be even better if a foobar component (or foobar itstelf... hint, hint This post has been edited by Yirkha: Jan 18 2009, 03:07 |
|
|
|
Mar 3 2009, 17:36
Post
#21
|
|
![]() Group: Members Posts: 92 Joined: 15-October 04 From: Linz, Austria Member No.: 17657 |
It's the core what does the saving, this component only launches the menu command to do it, so there is no reliable control over that part. Ummm... unless there's no way to know where the config file itself resides couldn't the component just do a regular ol' file copy to a (configurable) backup directory *before* making Foobar2000 save it's configuration? That should pretty much have the desired effect... -------------------- np: 4'33"
|
|
|
|
Mar 3 2009, 18:17
Post
#22
|
|
![]() Group: FB2K Moderator Posts: 2359 Joined: 30-November 07 Member No.: 49158 |
Thank you, such ideas are welcome.
It is possible to retrieve the path of profile directory. Now what files should be copied? You can't know if some component writes extra configuration files (e.g. PlaybackStatistics.dat). Copying everything is not a good solution - for example, portable installations use the installation directory as profile directory, so all components and any other random junk someone stores there would be copied as well each time. Configurable list of files to back up? No thanks. -------------------- Full-quoting makes you scroll past the same junk over and over.
|
|
|
|
Mar 6 2009, 14:55
Post
#23
|
|
|
Group: Members Posts: 134 Joined: 19-June 07 Member No.: 44533 |
thanks for the work on the plug-in, trying it out today. it's pretty much exactly what i've been hoping for and i'm glad i just happened to stumble on it today.
I agree, there is no need to automatically copy the files from the %appdata%\foobar2000 and %programfiles%\foobar2000 folders, you can easily do that already do that using backup scripts (robocopy or winrar, etc). besides it doesn't really need to be done that often. the most useful thing for me is the autosaving of playlists and playback stats database. will be very useful on my work laptop, where I have to test software and occasionally BSOD after hours of having foobar open playing tracks. I use foo_removeplayed, so this will awesome as i won't have to manually edit any playlists i was listening to after a crash. also, i didn't know about the hidden menu file -> save configuration ;-) learn something new about foobar every day i guess. |
|
|
|
Mar 21 2009, 12:30
Post
#24
|
|
![]() Group: FB2K Moderator Posts: 2359 Joined: 30-November 07 Member No.: 49158 |
v.0.0.3 released, addresses issue with autosaving after number of tracks with Preferences dialog open.
-------------------- Full-quoting makes you scroll past the same junk over and over.
|
|
|
|
Mar 21 2009, 18:54
Post
#25
|
|
|
Group: Developer Posts: 650 Joined: 26-September 07 Member No.: 47369 |
Doesn't work with foobar2000 0.9.5.6 anymore.
On startup you get the message: Module "foo_jesus.dll" has been removed since last run. Would you like to keep its settings? After answering the question for keeping the settings with yes or now you get: Failed to load DLL: foo_jesus.dll Reason: Die angegebene Prozedur wurde nicht gefunden. (Translation: The specified procedure could not be found) This post has been edited by fbuser: Mar 21 2009, 18:55 |
|
|
|
![]() ![]() |
|
Lo-Fi Version | Time is now: 20th June 2013 - 10:08 |