Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
What's new
7
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Open sidebar
Bob Tanner
packer-windows
Commits
fab0ac8f
Commit
fab0ac8f
authored
Apr 05, 2016
by
Stefan Scherer
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Set power plan to high performance
parent
96ef0364
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
8 additions
and
0 deletions
+8
-0
scripts/set-powerplan.ps1
scripts/set-powerplan.ps1
+7
-0
windows_10.json
windows_10.json
+1
-0
No files found.
scripts/set-powerplan.ps1
0 → 100644
View file @
fab0ac8f
Try
{
$HighPerf
=
powercfg
-l
|
%
{
if
(
$_
.
contains
(
"High performance"
))
{
$_
.
split
()[
3
]}}
$CurrPlan
=
$
(
powercfg
-getactivescheme
)
.
split
()[
3
]
if
(
$CurrPlan
-ne
$HighPerf
)
{
powercfg
-setactive
$HighPerf
}
}
Catch
{
Write-Warning
-Message
"Unable to set power plan to high performance"
}
windows_10.json
View file @
fab0ac8f
...
...
@@ -59,6 +59,7 @@
"./scripts/fixnetwork.ps1"
,
"./scripts/disable-winrm.ps1"
,
"./scripts/enable-winrm.ps1"
,
"./scripts/set-powerplan.ps1"
,
"./scripts/microsoft-updates.bat"
,
"./scripts/win-updates.ps1"
,
"./scripts/oracle-cert.cer"
...
...
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