w10install/optional/install-ntlite.cmd
Michael H.G. Schmidt 5f7a0941b9 several tweaks
2023-01-15 17:52:06 +01:00

45 lines
1.0 KiB
Batchfile

@echo off
call check-for-admin
if %ERRORLEVEL% neq 0 exit /b
set CONFIG=config\install-ntlite.txt
set EXE=..\software\ntlite-setup.exe
set SETTINGS=..\company\ntlite-settings.xml
set LICENSE=..\company\ntlite-license.dat
set STARTMENU=%PROGRAMDATA%\"Microsoft\Windows\Start Menu\Programs"
set STARTMENU_USER=%APPDATA%\"Microsoft\Windows\Start Menu\Programs"
if NOT EXIST %EXE% (
echo ERROR: %EXE% not found!
exit /b
)
echo ####### %0 #######
echo installing NTLite ...
start /wait %EXE% /LOADINF=%CONFIG% /NORESTART /NOCANCEL /SILENT /SUPPRESSMSGBOXES /CLOSEAPPLICATIONS
echo moving NTLite startmenu shortcut ...
mkdir %STARTMENU%\Tools 2>nul
move /Y %STARTMENU%\"NTLite\NTLite.lnk" %STARTMENU%\Tools 2>nul
echo cleanup ...
rd /S /Q %STARTMENU%\"NTLite" 2>nul
if EXIST %LICENSE% (
echo installing license ...
copy /Y %LICENSE% "%PROGRAMFILES%\NTLite\license.dat"
)
if EXIST %SETTINGS% (
echo copying settings ...
copy /Y %SETTINGS% "%PROGRAMFILES%\NTLite\settings.xml"
)
rem refresh desktop (W10 style)
ie4uinit.exe -show
echo ####### %0 #######
pause