@echo off :all set /p all=Import all default settings (Y/N): IF [%all%] == [n] GOTO webservices IF [%all%] == [N] GOTO webservices IF [%all%] == [y] GOTO webservices IF [%all%] == [Y] GOTO webservices GOTO all :webservices IF [%all%] == [y] GOTO set_webservices IF [%all%] == [Y] GOTO set_webservices set /p webservices=Import a list of web services (WMS/WFS/WCS/CSW) (Y/N): IF [%webservices%] == [n] GOTO ui_settings IF [%webservices%] == [N] GOTO ui_settings IF [%webservices%] == [y] GOTO set_webservices IF [%webservices%] == [Y] GOTO set_webservices GOTO webservices :set_webservices echo Importing web map and data services... regedit /s .\QGIS_Settings\wms_connections.reg regedit /s .\QGIS_Settings\wms_list.reg regedit /s .\QGIS_Settings\wcs_connections.reg regedit /s .\QGIS_Settings\wcs_list.reg regedit /s .\QGIS_Settings\csw_connections.reg echo %webservices% :ui_settings IF [%all%] == [y] GOTO set_ui_settings IF [%all%] == [Y] GOTO set_ui_settings set /p ui_settings=Import various User Interface settings (e.g. english language, snapping defaults, default projection settings ...) (Y/N): IF [%ui_settings%] == [n] GOTO postgis IF [%ui_settings%] == [N] GOTO postgis IF [%ui_settings%] == [y] GOTO set_ui_settings IF [%ui_settings%] == [Y] GOTO set_ui_settings GOTO ui_settings :set_ui_settings echo Setting ui_settings to engish... regedit.exe /s .\QGIS_Settings\english_local.reg regedit.exe /s .\QGIS_Settings\digitising.reg regedit.exe /s .\QGIS_Settings\gdal_geotiff.reg regedit.exe /s .\QGIS_Settings\projections.reg :postgis IF [%all%] == [y] GOTO set_postgis IF [%all%] == [Y] GOTO set_postgis set /p postgis=Import default PostGIS connections (Y/N): IF [%postgis%] == [n] GOTO plugins IF [%postgis%] == [N] GOTO plugins IF [%postgis%] == [y] GOTO set_postgis IF [%postgis%] == [Y] GOTO set_postgis GOTO postgis :set_postgis echo Importing PostGIS connections... regedit.exe /s .\QGIS_Settings\postgis_connection_ecogis.reg regedit.exe /s .\QGIS_Settings\postgis_connection.reg :plugins IF [%all%] == [y] GOTO set_plugins IF [%all%] == [Y] GOTO set_plugins set /p plugins=Import default QGIS plugins (Y/N): IF [%plugins%] == [n] GOTO templates IF [%plugins%] == [N] GOTO templates IF [%plugins%] == [y] GOTO set_plugins IF [%plugins%] == [Y] GOTO set_plugins GOTO plugins :set_plugins echo Importing QGIS plugins (may take a while)... IF exist %UserProfile%\.qgis2 ( echo QGIS user profile folder exists ) ELSE ( mkdir %UserProfile%\.qgis2 && echo QGIS user profile folder %UserProfile%\.qgis2 created) IF exist %UserProfile%\.qgis2\python ( echo QGIS python folder exists ) ELSE ( mkdir %UserProfile%\.qgis2\python && echo QGIS python folder created) IF exist %UserProfile%\.qgis2\python\plugins ( echo QGIS plugins folder exists ) ELSE ( mkdir %UserProfile%\.qgis2\python\plugins && echo QGIS plugins folder created) ::#xcopy .\QGIS_settings\.qgis2\python\plugins\* %UserProfile%\.qgis2\python\plugins\ /E /S /C /Q ::regedit /s .\QGIS_Settings\python_plugins.reg :templates IF [%all%] == [y] GOTO set_templates IF [%all%] == [Y] GOTO set_templates set /p templates=Import default project and map templates (Y/N): IF [%templates%] == [n] GOTO end IF [%templates%] == [N] GOTO end IF [%templates%] == [y] GOTO set_templates IF [%templates%] == [Y] GOTO set_templates GOTO templates :set_templates echo Importing map and project templates... IF exist %UserProfile%\.qgis2 ( echo QGIS user profile folder exists ) ELSE ( mkdir %UserProfile%\.qgis2 && echo QGIS user profile folder %UserProfile%\.qgis2 created) IF exist %UserProfile%\.qgis2\project_templates ( echo Templates folder exists ) ELSE ( mkdir %UserProfile%\.qgis2\project_templates && echo QGIS Templates folder created) xcopy .\QGIS_settings\.qgis2\project_templates\* %UserProfile%\.qgis2\project_templates\ /E /S /C set /p quit=Press any key to close the dialog... :end