How to automatically back up your config on system start

If you're like me, you've spent many hours tweaking your copy of DOpus to fit your needs perfectly, and you would hate to lose all this hard work. It's easy enough to make a backup of your DOpus configuration, but for some of us, it's not easy to remember to back things up. So here is a short tutorial that will help you set things up so that every time you start your computer, a backup is made of your DOpus configuration files. These backups are kept for 10 days, and are then deleted.

Note - This tutorial assumes you chose to use shared configuration files when you installed DOpus. This will be true for most users. If you are using private configuration files, you will need to adjust the paths in the batch file accordingly.

Requirements:
WinRAR: http://www.rarlab.com/
Forfiles: http://www.ss64.com/nt/forfiles.html (click update to access the download area)

Steps:

  1. Download and install WinRAR if you don't already have it.
  2. Download Forfiles.exe, and put it in your WinRAR directory.
  3. Open Notepad, and paste the following into a new text file:
@ECHO OFF
cd "C:\Documents and Settings\All Users\Application Data\GPSoftware\"
set path="%programfiles%\WinRAR\";%path%
rar a -agYYYYMMDD "Backup\backup.rar" "Directory Opus"
forfiles -pBackup\ -s -m*.rar -d-10 -c"CMD /C del /q @FILE"
  1. Save the file as DopusBackup.bat, and place it in your Startup folder.
  2. Make a folder called Backup in C:\Documents and Settings\All Users\Application Data\GPSoftware\

That's it! Now, every time your computer starts, your dopusdata folder will be archived in your new Backup folder. Be aware that if you boot more than once in a day, the file will be overwritten, since the filename is based on the current date. Also, every time this batch file runs, any backups older than 10 days are deleted.

See also: FAQ: How to back-up or locate your Opus configuration, which describes how to find your configuration files regardless of Windows version or shared/private configuration.

[quote="garbanzo"]
4. Save the file as DopusBackup.bat, and place it in your Startup folder.[/quote]

What was the location of Startup folder? I'm using windows 7 but I can't locate the path of Startup folder...

Sorry man I'm not a computer wiz.

Type /startup into Opus (either the Location bar or into the find-as-you-type field that pops-up when you type into the file display) and it'll find the folder for you.

Type /startup into Opus (either the Location bar or into the find-as-you-type field that pops-up when you type into the file display) and it'll find the folder for you.[/quote]

Thanks, you help me a lot! and it made easier for me to use it....

HI,

I've got a problem locating and downloading the 'forfiles.exe' . There doesn't seem to be an 'update'/download-area on the page.
Does anyone know where/how to get the file?

cya

[quote="Loki"]HI,

I've got a problem locating and downloading the 'forfiles.exe' . There doesn't seem to be an 'update'/download-area on the page.
Does anyone know where/how to get the file?

cya[/quote]

I don't know anything about forfiles, but it looks like you can get it at petri.co.il/download_free_reskit_tools.htm .

Thanks for the link. I will look into it.