-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathPrintRepoSettings.bat
More file actions
69 lines (55 loc) · 1.85 KB
/
PrintRepoSettings.bat
File metadata and controls
69 lines (55 loc) · 1.85 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
@echo off
setlocal
:: Prints values of environment variables that are used for updating
:: repositories, e.g. by the script UpdateREpo.bat .
:: Execution of the script does not have any siide effect such as setting
:: on changing variables in the calling environment (executiion block is
:: enclosed in setloca / endlocal calls).
:: BEFORE printing the values, this script treats eventual parameters as
:: another command with parameters and executes that command. This adds
:: the possibility to run the setting script before printing variable
:: values. This is done in a single command line, and combination of
:: scripts does not have side effects.
:: Reset the error level (by running an always successfull command):
ver > nul
echo.
echo ======================================== %~n0%~x0:
echo.
if "%~1" EQU "" goto AfterCommandCall
:: If any command-line arguments were specified then assemble a
:: command-line from these arguments and execute it:
:: Assemble command-line from the remaining arguments....
set CommandLine6945="%~1"
:loop
shift
if [%1]==[] goto afterloop
set CommandLine6945=%CommandLine6945% "%~1"
goto loop
:afterloop
:: Call the assembled command-line:
call %CommandLine6945%
:AfterCommandCall
echo.
echo ======== Rpository settings: (%~n0%~x0):
echo.
echo Parameters for repository update:
echo.
echo ModuleDirRelative: "%ModuleDirRelative%"
echo ModuleDir: "%ModuleDir%"
echo CheckoutBranch: "%CheckoutBranch%"
echo Remote: "%Remote%"
echo RemoteSecondary: "%RemoteSecondary%"
echo RemoteLocal: "%RemoteLocal%"
echo.
echo RepositoryAddress: "%RepositoryAddress%"
echo RepositoryAddressSecondary: "%RepositoryAddressSecondary%"
echo RepositoryAddressLocal: "%RepositoryAddressLocal%"
echo.
echo ModuleGitSubdir: "%ModuleGitSubdir%"
echo.
:finalize
ver > nul
echo.
echo ======== End: %~n0%~x0
echo.
endlocal