bugfix and relocation
This commit is contained in:
parent
6d1161a4f2
commit
b067277945
@ -1,12 +1,12 @@
|
||||
; SNAPCONTROL config file.
|
||||
; https://gitea.exabyte-systems.com/WINDOWS/snapcontrol
|
||||
; https://gitea.exabyte-systems.com/WINDOWS/snapcontrol.git
|
||||
;
|
||||
; This tool creates an image backups of windows machines,
|
||||
; it uses the Drive Snapshot tool by Tom Ehlert Software.
|
||||
; Please support this great tool and buy a license.
|
||||
; http://www.drivesnapshot.de/en/order.htm
|
||||
;
|
||||
; Copyright (c) 2019-2021 Michael H.G. Schmidt
|
||||
; Copyright (c) 2019-2024 Michael H.G. Schmidt
|
||||
; EMAIL: michael@schmidt2.de
|
||||
; Released under the MIT license.
|
||||
;
|
||||
@ -14,7 +14,8 @@
|
||||
;
|
||||
|
||||
[BACKUP]
|
||||
; path where snapshot.exe and cmail.exe is located ...
|
||||
; path where cmail.exe is located ...
|
||||
; (snaphot64.exe, this inifile and snapcontrol.exe must be always located in %WINDIR%!)
|
||||
BinPath = c:\tools
|
||||
|
||||
; target PATH examples:
|
||||
@ -80,6 +81,9 @@ EjectMedia = yes
|
||||
; should we ask for a shutdown after backup ? (yes/no)
|
||||
AskForShutdown = yes
|
||||
|
||||
; should we force a shutdown after the backup run?
|
||||
; user will NOT be asked for consent! (useful for schedule mode "TIME" and silent mode)
|
||||
ForcedShutdown = no
|
||||
|
||||
[LOGGING]
|
||||
|
@ -3,40 +3,47 @@ call check-for-admin
|
||||
if %ERRORLEVEL% neq 0 exit /b
|
||||
|
||||
set TOOLS=%SystemDrive%\tools
|
||||
set INIFILE=..\scripts\config\snapcontrol.ini
|
||||
set INIFILE=config\snapcontrol.ini
|
||||
set SOFTWARE=..\software
|
||||
set STARTMENU="%PROGRAMDATA%\Microsoft\Windows\Start Menu\Programs\tools"
|
||||
|
||||
if NOT EXIST %SOFTWARE%\snapcontrol.exe (
|
||||
echo ERROR: %SOFTWARE%\snapcontrol.exe not found!
|
||||
exit /b
|
||||
)
|
||||
|
||||
echo ####### %0 #######
|
||||
|
||||
echo killing snapcontrol processes...
|
||||
taskkill /F /IM snapcontrol.exe 2>nul
|
||||
|
||||
echo killing snapshot processes...
|
||||
taskkill /F /IM snapshot64.exe 2>nul
|
||||
|
||||
echo copy snapcontrol binary to [ %windir% ] ...
|
||||
copy /Y %SOFTWARE%\snapcontrol.exe %windir% 2>nul
|
||||
|
||||
if EXIST %SOFTWARE%\snapshot64_licensed.exe (
|
||||
|
||||
echo copying LICENSED snapshot64 to %windir% ...
|
||||
copy /Y %SOFTWARE%\snapshot64_licensed.exe %windir%\snapshot64.exe
|
||||
|
||||
) else (
|
||||
|
||||
echo copying STANDARD snapshot64 to boot image ...
|
||||
copy /Y %SOFTWARE%\snapshot64.exe %windiw%
|
||||
|
||||
copy /Y %SOFTWARE%\snapshot64.exe %windir%
|
||||
)
|
||||
|
||||
if NOT EXIST %windir%\snapcontrol.ini (
|
||||
|
||||
echo copying STANDARD inifile to %windir% ...
|
||||
copy /Y %INIFILE% %windir%
|
||||
|
||||
) else (
|
||||
|
||||
echo inifile already copied. nothing to do!
|
||||
|
||||
)
|
||||
|
||||
echo creating scheduler task ...
|
||||
%windir%\snapcontrol /I
|
||||
|
||||
echo copy startmenu link ...
|
||||
copy /Y "startmenu\Drive Snapshot.lnk" %STARTMENU%
|
||||
|
||||
echo ####### %0 #######
|
||||
pause
|
||||
|
||||
|
BIN
optional/startmenu/Drive Snapshot.lnk
Normal file
BIN
optional/startmenu/Drive Snapshot.lnk
Normal file
Binary file not shown.
Binary file not shown.
Loading…
Reference in New Issue
Block a user