From 9c6d829991439bbd3b8b6fce5f94caeaa9ab9deb Mon Sep 17 00:00:00 2001 From: Tal Auslander Date: Tue, 9 Jun 2015 11:14:44 +0300 Subject: [PATCH] add force parameter to win_get_url --- lib/ansible/modules/windows/win_get_url.ps1 | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/ansible/modules/windows/win_get_url.ps1 b/lib/ansible/modules/windows/win_get_url.ps1 index 96189d69113..e5e1ea73c83 100644 --- a/lib/ansible/modules/windows/win_get_url.ps1 +++ b/lib/ansible/modules/windows/win_get_url.ps1 @@ -40,7 +40,9 @@ Else { Fail-Json $result "missing required argument: dest" } -If (-not (Test-Path $dest)) { +$force = Get-Attr -obj $params -name "force" "no" + +If ($force -eq "yes" -or -not (Test-Path $dest)) { $client = New-Object System.Net.WebClient Try {