W11 ISO Post-Setup Commands

GamingHen

New Member
Messages
12
Reaction score
1
Hey i want to execute some cmd commands on installation to do 2 things:
- remove microsoft edge desktop shortcut
- activate and set active the ultimate performance energy plan

but only the first powercfg command seems to be executed/working
View attachment 10222
 

Attachments

When using a custom power plan, you need to export and then import the plan file.

From the original PC:
powercfg /export my_power_plan.pow [e9a4...eb61]

1. Add "my_power_plan.pow" to Post-Setup as a normal file.
NTLite will list a new pathname in the Parameters column.​

2. Change the first command to "powercfg /import "%WINDIR%.....", using the path provided by Step 1.

3. 2nd powercfg command stays the same.
 
When using a custom power plan, you need to export and then import the plan file.

From the original PC:
powercfg /export my_power_plan.pow [e9a4...eb61]

1. Add "my_power_plan.pow" to Post-Setup as a normal file.
NTLite will list a new pathname in the Parameters column.​

2. Change the first command to "powercfg /import "%WINDIR%.....", using the path provided by Step 1.

3. 2nd powercfg command stays the same.
hey thanks for the answer, but the first powercfg is a power plan that already part of windows, but hidden. its not custom. everyone can activate it with that command
 
Forgot it's "Ultimate". hellbovine will jump in and remind you why it's BS.

Why do you need to duplicate the plan, if you're not editing it? /setactive is enough to make it work.
 
Forgot it's "Ultimate". hellbovine will jump in and remind you why it's BS.

Why do you need to duplicate the plan, if you're not editing it? /setactive is enough to make it work.
thanks for the answer, okay ill try just to setactive, maybe that messed something up, do i need to enable "OEM SetupComplete" btw?
 
OEM SetupComplete is required if your PC has a built-in license key (Dell, HP, Lenovo). It will also work on any random PC.
 
I don't know if this works on W11, but it works for me on a clean install of W10 21H2.

; Hidden > Desktop > Create shortcut to Microsoft Edge > Disabled
[HKEY_LOCAL_MACHINE\SOFTWARE\Policies\Microsoft\EdgeUpdate]
"CreateDesktopShortcutDefault"=dword:00000000
 
When using a custom power plan, you need to export and then import the plan file.

From the original PC:
powercfg /export my_power_plan.pow [e9a4...eb61]

1. Add "my_power_plan.pow" to Post-Setup as a normal file.
NTLite will list a new pathname in the Parameters column.​

2. Change the first command to "powercfg /import "%WINDIR%.....", using the path provided by Step 1.

3. 2nd powercfg command stays the same.
Hey that works, except the 3. point, because the my custom power plan always gets a different GUID, is there a workaround?
 
powercfg /import with no [GUID] will assign it a new random GUID.

powercfg /import "%WINDIR%...." [e9a4...eb61]
powercfg /setactive [e9a4...eb61]
 
Back
Top