1*cdf0e10cSrcweir@echo off 2*cdf0e10cSrcweirset MYBOOTSTRAPTESTVALUE=0 3*cdf0e10cSrcweirecho 1 4*cdf0e10cSrcweir.\testbootstrap 1 -env:MYBOOTSTRAPTESTVALUE=1 5*cdf0e10cSrcweir 6*cdf0e10cSrcweirecho 2 7*cdf0e10cSrcweir.\testbootstrap.exe file 8*cdf0e10cSrcweir 9*cdf0e10cSrcweirecho 3 10*cdf0e10cSrcweir.\testbootstrap.Exe file 11*cdf0e10cSrcweir 12*cdf0e10cSrcweirecho 4 13*cdf0e10cSrcweir.\testbootstrap.bin file 14*cdf0e10cSrcweir 15*cdf0e10cSrcweirecho 5 16*cdf0e10cSrcweir.\testbootstrap.Bin file 17*cdf0e10cSrcweir 18*cdf0e10cSrcweirecho 6 19*cdf0e10cSrcweir.\testbootstrap 0 -env:INIFILENAME= 20*cdf0e10cSrcweir 21*cdf0e10cSrcweirecho 7 22*cdf0e10cSrcweirset MYBOOTSTRAPTESTVALUE= 23*cdf0e10cSrcweirrem simply ignore the file .... 24*cdf0e10cSrcweir.\testbootstrap default -env:INIFILENAME= 25*cdf0e10cSrcweir 26*cdf0e10cSrcweirecho 8 27*cdf0e10cSrcweir.\testbootstrap default -env:MYBOOTSTRAPTESTVALUE2=1 -env:INIFILENAME= 28*cdf0e10cSrcweir 29*cdf0e10cSrcweirecho 30*cdf0e10cSrcweirecho "macro tests" 31*cdf0e10cSrcweirecho 32*cdf0e10cSrcweir 33*cdf0e10cSrcweirrem simple macro expansion 34*cdf0e10cSrcweirecho 9 35*cdf0e10cSrcweir.\testbootstrap _first_second_third_ -env:FIRST=first -env:SECOND=second -env:THIRD=third -env:MYBOOTSTRAPTESTVALUE=_${FIRST}_${SECOND}_${THIRD}_ 36*cdf0e10cSrcweir 37*cdf0e10cSrcweirrem simple quoting 38*cdf0e10cSrcweirecho 10 39*cdf0e10cSrcweir.\testbootstrap _${FIRST}_${SECOND}_${THIRD}_ -env:FIRST=first -env:SECOND=second -env:THIRD=third -env:MYBOOTSTRAPTESTVALUE=_\$\{FIRST\}_\$\{SECOND\}_\$\{THIRD\}_ 40*cdf0e10cSrcweir 41*cdf0e10cSrcweirrem simple ini access 42*cdf0e10cSrcweirecho 11 43*cdf0e10cSrcweir.\testbootstrap TheKeysValue -env:MYBOOTSTRAPTESTVALUE=${./bootstraptest.ini:TheSection:TheKey} 44*cdf0e10cSrcweir 45*cdf0e10cSrcweirrem ini access with simple macro expansion 46*cdf0e10cSrcweirecho 12 47*cdf0e10cSrcweir.\testbootstrap TheKeysValue -env:ININAME=./bootstraptest.ini -env:SECTIONNAME=TheSection -env:KEYNAME=TheKey -env:MYBOOTSTRAPTESTVALUE=${$ININAME:$SECTIONNAME:$KEYNAME} 48*cdf0e10cSrcweir 49*cdf0e10cSrcweirrem ini access with complex macro expansion 50*cdf0e10cSrcweirecho 13 51*cdf0e10cSrcweir.\testbootstrap TheKeysValue -env:ININAME=./bootstraptest.ini -env:MYBOOTSTRAPTESTVALUE=${$ININAME:${$ININAME:SecondSection:IndirectSection}:${$ININAME:SecondSection:IndirectKey}} 52*cdf0e10cSrcweir 53*cdf0e10cSrcweirrem test no infinit recursion 54*cdf0e10cSrcweirecho 14 55*cdf0e10cSrcweir.\testbootstrap "***RECURSION DETECTED***" -env:MYBOOTSTRAPTESTVALUE=$MYBOOTSTRAPTESTVALUE 56*cdf0e10cSrcweir 57*cdf0e10cSrcweirrem test unicode 58*cdf0e10cSrcweirecho 15 59*cdf0e10cSrcweir.\testbootstrap AAABBBCCC000 -env:MYBOOTSTRAPTESTVALUE=\u0041\u0041\u0041\u0042\u0042\u0042\u0043\u0043\u0043\u0030\u0030\u0030 60*cdf0e10cSrcweir 61*cdf0e10cSrcweir 62*cdf0e10cSrcweir@echo bootstrap test finished