diff --git a/scripts/deploy-ftp.ps1 b/scripts/deploy-ftp.ps1 index 8ec40ec..fc554c4 100644 --- a/scripts/deploy-ftp.ps1 +++ b/scripts/deploy-ftp.ps1 @@ -50,15 +50,15 @@ Assert-Tool $WinScpPath function Read-PlainOrPrompt([string]$Value, [string]$Prompt, [switch]$Secure) { if ($Value) { return $Value } if ($Secure) { - $secure = Read-Host -AsSecureString $Prompt + $secure = Read-Host -Prompt $Prompt -AsSecureString return [Runtime.InteropServices.Marshal]::PtrToStringUni( [Runtime.InteropServices.Marshal]::SecureStringToBSTR($secure) ) } - return Read-Host $Prompt + return Read-Host -Prompt $Prompt } -$FtpPassword = Read-PlainOrPrompt $FtpPassword "FTP password" +$FtpPassword = Read-PlainOrPrompt $FtpPassword "FTP password" -Secure $WinRmCredentialPass = Read-PlainOrPrompt $WinRmCredentialPass "WinRM password" -Secure Write-Host "1) Publishing..." -ForegroundColor Cyan