Backup.bat

From help.computerisms.ca
Revision as of 19:53, 9 September 2016 by Bayan (talk | contribs)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

Put this in a text file and save it on the desktop. Use computer's disk management to ensure removable drive always gets drive letter e:. User can plug in his drive, double click the file, and backup his data.

@echo off

ren e:\daily.4 daily.5
ren e:\daily.3 daily.4
ren e:\daily.2 daily.3
ren e:\daily.1 daily.2
ren e:\daily.0 daily.1

mkdir e:\daily.0
mkdir e:\daily.0\docs
mkdir e:\daily.0\mail
mkdir e:\daily.0\favs


xcopy /I /Y /E /C "C:\Documents and Settings\staff\My Documents" e:\daily.0\docs
xcopy /I /Y /E /C "C:\Documents and Settings\staff\Application Data\Thunderbird\Profiles" e:\daily.0\mail
xcopy /I /Y /E /C "C:\Documents and Settings\staff\Favorites" e:\daily.0\favs