Skip to content

Commit

Permalink
Fix install PSWindowsUpdate module script
Browse files Browse the repository at this point in the history
  • Loading branch information
Default User committed Nov 20, 2023
1 parent 05a8286 commit 1230220
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 9 deletions.
5 changes: 2 additions & 3 deletions docs/Install--PSWindowsUpdate-Module.html
Original file line number Diff line number Diff line change
Expand Up @@ -361,9 +361,8 @@ <h3 id="checkifpswindowsupdatemoduleisinstalled">
$module = Get-Module -ListAvailable -Name PSWindowsUpdate

if (-not $module) {
Install-Module -Name PSWindowsUpdate -Force -Verbose

Import-Module PSWindowsUpdate
Install-Package -Name PSWindowsUpdate -Verbose -Force
Import-Module -Name PSWindowsUpdate -Verbose
} else {
Write-Output &quot;PSWindowsUpdate module is already installed.&quot;
}
Expand Down
5 changes: 2 additions & 3 deletions docs/Update-Windows-for-Security-Updates.html
Original file line number Diff line number Diff line change
Expand Up @@ -427,9 +427,8 @@ <h3 id="checkifpswindowsupdatemoduleisinstalled">
$module = Get-Module -ListAvailable -Name PSWindowsUpdate

if (-not $module) {
Install-Module -Name PSWindowsUpdate -Force -Verbose

Import-Module PSWindowsUpdate
Install-Package -Name PSWindowsUpdate -Verbose -Force
Import-Module -Name PSWindowsUpdate -Verbose
} else {
Write-Output &quot;PSWindowsUpdate module is already installed.&quot;
}
Expand Down
5 changes: 2 additions & 3 deletions steps/checkifpswindowsupdatemoduleisinstalled/script.txt
Original file line number Diff line number Diff line change
@@ -1,9 +1,8 @@
$module = Get-Module -ListAvailable -Name PSWindowsUpdate

if (-not $module) {
Install-Module -Name PSWindowsUpdate -Force -Verbose

Import-Module PSWindowsUpdate
Install-Package -Name PSWindowsUpdate -Verbose -Force
Import-Module -Name PSWindowsUpdate -Verbose
} else {
Write-Output "PSWindowsUpdate module is already installed."
}

0 comments on commit 1230220

Please sign in to comment.