The Toolkit variable $envTemp provides incorrect information.
Copy-File -Path "$dirSupportFiles\*.*” -Destination "$envTemp\tempfiles"
Copy-File -Path …\supportfiles\*.* -Destination ...\Temp\\tempfiles
return with an extra \ after temp
It is not a bug it just might not be what you expected.
$envTemp is a result of calling GetTempPath, which returns the first working path in this list:
- The path specified by the TMP environment variable.
- The path specified by the TEMP environment variable.
- The path specified by the USERPROFILE environment variable.
- The Windows directory.
Open powershell and run than [IO.Path]::GetTempPath()
In the toolkit you cannot use $envtemp\BackUp this gives you after result of calling GetTempPath()
Just tested it. Returns correct value running under user admin. Other than trailing backslash in the variables I see no issue here.
Running under system yields similar results.