mirror of
git://code.qt.io/qt/qt5.git
synced 2026-04-25 06:07:47 +08:00
Remove hardcoded download path
Previously all files got downloaded to a hardcoded path, including the username for the CI machines. Usually, it does not fit the username of a local development machine, complicating to reproduce bugs. Introduce Get-(Default)DownloadLocation functions in helpers to specify the default download location. This helps to run the provisioning scripts on a local machine. Change-Id: I761a92bf5e3e774358756a95dddb9a5d6ee54db9 Reviewed-by: Oliver Wolff <oliver.wolff@qt.io>
This commit is contained in:
@@ -68,6 +68,17 @@ function BadParam
|
||||
throw("You must specify $Description")
|
||||
}
|
||||
|
||||
function Get-DefaultDownloadLocation
|
||||
{
|
||||
return $env:USERPROFILE + "\downloads\"
|
||||
}
|
||||
|
||||
function Get-DownloadLocation
|
||||
{
|
||||
Param ([string]$TargetName = $(BadParam("a target filename")))
|
||||
return (Get-DefaultDownloadLocation) + $TargetName
|
||||
}
|
||||
|
||||
function Download
|
||||
{
|
||||
Param (
|
||||
|
||||
Reference in New Issue
Block a user