Short recipes only.
First project walkthrough → SIMPLE-GUIDE.md · All options → USAGE.md · Overview → README
Run PowerShell as Administrator. After -Init -WorkDirectory ..., the same window usually needs no path again.
Copy your drivers into Add-Drivers (folders with .inf files), then:
.\WinPE-Builder.ps1 -Build -ISO -Force -AddPackage packages.pePrefer packages with .inf + .cat + .sys (not setup.exe alone).
| File | Notes |
|---|---|
Add-Scripts\startnet.cmd |
Keep wpeinit |
Add-Scripts\winpe.jpg |
About 800×600 — copy your wallpaper here |
.\WinPE-Builder.ps1 -Build -ISO -Force -AddPackage packages.peCreated on -Init. Uncomment optional OCs; comment out defaults you do not want.
Open packages.pe in any text editor, then:
.\WinPE-Builder.ps1 -Build -ISO -Force -AddPackage packages.pe| Tip | Detail |
|---|---|
| File is the set | When you pass packages.pe, only uncommented lines install (built-in defaults are not re-merged) |
| Missing cab | Logged as a warning; build continues |
Full rules → USAGE — packages.pe.
.\WinPE-Builder.ps1 -Mount
# edit ...\WinPE-Root\mount
.\WinPE-Builder.ps1 -Save
# or
.\WinPE-Builder.ps1 -DiscardFormats the USB drive.
.\WinPE-Builder.ps1 -Build -USB F: -Force -AddPackage packages.pe
.\WinPE-Builder.ps1 -Build -ISO -USB F: -Force -AddPackage packages.peOnly with -Init. Replaces the ADK boot.wim after copype. Point at your WinPE boot.wim:
.\WinPE-Builder.ps1 -Init -WorkDirectory . `
-Architecture amd64 `
-BootWimPath ".\path\to\your\boot.wim"
.\WinPE-Builder.ps1 -Build -ISO -Force -AddPackage packages.pe- Path must exist; image should be a WinPE boot.wim (not
install.wim). - Mount/build use index 1.
- On re-Init, pass
-BootWimPathagain if you still want that base image.
Details → USAGE — Custom boot.wim.
.\WinPE-Builder.ps1 -Discard
.\WinPE-Builder.ps1 -Clean -Force# Built-in defaults + extra OC names (no packages.pe file)
.\WinPE-Builder.ps1 -Build -ISO -Force -AddPackage WinPE-WDS-Tools,WinPE-Dot3Svc
# Locale
.\WinPE-Builder.ps1 -Build -ISO -Force `
-Language de-de -TimeZone 'W. Europe Standard Time' `
-AddPackage packages.pe
# Minimal set without built-in defaults
.\WinPE-Builder.ps1 -Build -ISO -Force `
-NoDefaultPackages -AddPackage WinPE-WMI,WinPE-NetFx,WinPE-Scripting,WinPE-PowerShellTime zone names: tzutil /l
.\WinPE-Builder.ps1 -Build -ISO -PCA2023 -Force -AddPackage packages.pe
.\WinPE-Builder.ps1 -Build -USB F: -PCA2023 -Force -AddPackage packages.peDefault (no switch) = PCA 2011 (max compatibility).
When to use 2023: USAGE — Secure Boot.
New shell — do not -Init again:
.\WinPE-Builder.ps1 -WorkDirectory C:\MyWinPE-Project
.\WinPE-Builder.ps1 -Build -ISO -Force -AddPackage packages.peOr from the ZIP extract folder used as the project:
cd C:\path\to\extracted\WinPEBuilder
.\WinPE-Builder.ps1 -WorkDirectory .
.\WinPE-Builder.ps1 -Build -ISO -Force -AddPackage packages.pe| Goal | Run |
|---|---|
| New project (this folder) | -Init -WorkDirectory . |
| New project (custom path) | -Init -WorkDirectory C:\... |
| Custom base WIM | -Init … -BootWimPath ".\path\to\your\boot.wim" |
| Resume | -WorkDirectory . or -WorkDirectory C:\... |
| Packages file | Edit packages.pe then -AddPackage packages.pe |
| Mount / save / drop | -Mount · -Save · -Discard |
| ISO | -Build -ISO -Force -AddPackage packages.pe |
| ISO + PCA2023 | -Build -ISO -PCA2023 -Force -AddPackage packages.pe |
| USB | -Build -USB X: -Force -AddPackage packages.pe |
| Stuck | -Discard or -Clean -Force |
