Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
10
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
Bob Tanner
packer-windows
Commits
a5f96609
Unverified
Commit
a5f96609
authored
Feb 10, 2017
by
Stefan Scherer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add BeginWithRestart parameter
parent
d6b7b038
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
1 deletion
+7
-1
scripts/win-updates.ps1
scripts/win-updates.ps1
+7
-1
No files found.
scripts/win-updates.ps1
View file @
a5f96609
param
(
$
global
:
RestartRequired
=
0
,
$
global
:
MoreUpdates
=
0
,
$
global
:
MaxCycles
=
5
,
$MaxUpdatesPerCycle
=
500
)
$MaxUpdatesPerCycle
=
500
,
$BeginWithRestart
=
0
)
$Logfile
=
"C:\Windows\Temp\win-updates.log"
...
...
@@ -224,6 +225,11 @@ $script:SearchResult = New-Object -ComObject 'Microsoft.Update.UpdateColl'
$
script
:
Cycles
=
0
$
script
:
CycleUpdateCount
=
0
if
(
$BeginWithRestart
)
{
$
global
:
RestartRequired
=
1
Check-ContinueRestartOrEnd
}
Check-WindowsUpdates
if
(
$
global
:
MoreUpdates
-eq
1
)
{
Install-WindowsUpdates
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment