Files
setup_windows_2/app/install_greenshot.cmd
T

43 lines
1.7 KiB
Batchfile
Raw Normal View History

2025-08-27 14:38:18 +00:00
:: ------------------------------------------------------------
:: Installationsroutine
:: ------------------------------------------------------------
:: --- Option: Download in ein temporäres Verzeichnis
:: --- Kann für z.B. für GLPI abgeschaltet werden
set SAVEPATH=%SYSTEMDRIVE%\TEMP\install
2026-09-10 09:05:27 +02:00
MKDIR %SAVEPATH% 2> nul & CD /D %SAVEPATH%
2025-08-27 14:38:18 +00:00
:: --- Download Basis-URL, Dateiname und TEMP-Verzeichnis
2026-09-10 09:05:27 +02:00
:: https://github.com/greenshot/greenshot/releases/latest
set VERS=1.3.304
2025-08-27 14:38:18 +00:00
set BASEURL=https://github.com/greenshot/greenshot/releases/download/v%VERS%
set PROG=Greenshot-INSTALLER-%VERS%-RELEASE.exe
2026-09-10 09:05:27 +02:00
:: --- Lade Datei herunter
echo Starte Download.
curl -kLSsf %BASEURL%/%PROG% -o %SAVEPATH%\%PROG%
if %ERRORLEVEL% EQU 0 (echo Download OK! ) else ( echo Fehler %ERRORLEVEL% ist aufgetreten!)
2025-08-27 14:38:18 +00:00
:: --- Schalte Win11 Snipping tool ab:
2026-09-10 09:05:27 +02:00
echo Modifiziere Registry.
REG add "HKU\.DEFAULT\Control Panel\Keyboard" /t REG_SZ /v PrintScreenKeyForSnippingEnabled /d 0 /F
if %ERRORLEVEL% EQU 0 (echo OK! ) else ( echo Fehler %ERRORLEVEL% ist aufgetreten!)
REG add "HKCU\Control Panel\Keyboard" /t REG_SZ /v PrintScreenKeyForSnippingEnabled /d 0 /F
if %ERRORLEVEL% EQU 0 (echo OK! ) else ( echo Fehler %ERRORLEVEL% ist aufgetreten!)
2025-08-27 14:38:18 +00:00
:: --- Silent-Installation des Programms:
2026-09-10 09:05:27 +02:00
echo Erstelle Konfiguration.
2025-08-27 14:38:18 +00:00
(
echo [Setup]
echo Lang=de
echo Dir=
echo Group=Greenshot
echo NoIcons=0
echo Tasks=
) > greenshot.inf
2026-09-10 09:05:27 +02:00
:: --- Silent-Installation des Programms:
echo Starte Installation.
%PROG% /ALLUSERS /NORESTART /VERYSILENT /SUPPRESSMSGBOXES /SP- /LOADINF=greenshot.inf
if %ERRORLEVEL% EQU 0 (echo Installation OK! ) else ( echo Fehler %ERRORLEVEL% ist aufgetreten!)