@if NOT EXIST setup.bat goto ERR1
call setup
call mdd temp
md directory
md directory\a
md directory\b
genfile --file directory/a/a

@pause

%TEMPT% --create --file=archive.1 --listed-incremental=db.1 directory

@pause

@echo Remove directory b and create a file with this name.
@echo Previous versions were not able to restore over this file.
xdelete -dfrm directory\b -v0
genfile --file directory/b
genfile --file directory/a/b

@echo Second backup
%TEMPT% --create --file=archive.2 --listed-incremental=db.2 directory

@echo Delete all
xdelete -dfrm directory -v0

@pause
@echo Restore archive.1
%TEMPT% -xf archive.1 --listed-incremental=nul
@echo Restore archive.2
%TEMPT% -xf archive.2 --listed-incremental=nul
@echo Win32 versions is not able to restore over this file.
@pause

dir -s directory | sort
@cd ..
@goto END

:ERR1
@echo Can NOT locate setup.bat ... check name, location ...
@goto END

:END


