Compare commits

..

73 commits
legacy ... main

Author SHA1 Message Date
hax
35baeb90a0 README.md aktualisiert 2025-02-09 04:21:17 +00:00
hax
49dcd1b591 .github/FUNDING.yml aktualisiert
Signed-off-by: hax <hax@lainlounge.xyz>
2025-02-09 04:19:34 +00:00
hax
dec57a596e Obsolete stuff removed
Signed-off-by: hax <hax@lainlounge.xyz>
2025-02-09 04:14:38 +00:00
hax
d709995bf8 tiny11Coremaker.ps1 gelöscht
Signed-off-by: hax <hax@lainlounge.xyz>
2025-02-09 04:14:15 +00:00
hax
d7f2c6d4d4 README.md aktualisiert
Signed-off-by: hax <hax@lainlounge.xyz>
2025-02-09 04:13:26 +00:00
hax
2f3d125360 dockerfile added [WIP]
Signed-off-by: hax <hax@lainlounge.xyz>
2025-02-09 04:02:33 +00:00
hax
d0e336d0a2 Elevenbuilder.ps1 aktualisiert
Signed-off-by: hax <hax@lainlounge.xyz>
2025-02-09 03:50:37 +00:00
hax
6a58f48ed0 ElevenBuilder by h@x added
Signed-off-by: hax <hax@lainlounge.xyz>
2025-02-09 03:26:49 +00:00
NTDEV
af69a48265
Merge pull request #266 from qtqgyt/patch-1
Fix readme strikethrough (again)
2024-11-17 21:00:21 +02:00
NTDEV
1175178bf6
Merge pull request #277 from ntdevlabs/experimental
Fixes for 24H2
2024-11-17 20:52:59 +02:00
NTDEV
9ca84542f3
Fixes for 24H2 2024-11-17 20:51:22 +02:00
NTDEV
71e1e30e5e
Merge pull request #268 from Karl-WE/patch-1
Update tiny11maker.ps1 - use dism with PowerShell commands / QoL improvements
2024-11-17 20:36:53 +02:00
Karl Wester-Ebbinghaus
9b70166776
Update tiny11maker.ps1 - prevent outlook and devhome sideloading
added changes from #203
2024-11-07 03:03:19 +01:00
Karl Wester-Ebbinghaus
8c1a8d1045
Update tiny11maker.ps1
last corrections 
- to replace wrong command -ScratchDirectory with -Path
- putting param to the top
- make sure $Scratchdisk is $PSScriptRoot remove :\ or trailing \
- param will now have error handling for drive letters c-z and C-Z
- all references to $env:systemdrive or $($env:systemdrive) now generalized to $ScratchDisk


- tested the modified script and review log for errors
2024-11-07 02:19:39 +01:00
Karl Wester-Ebbinghaus
5ca27c740e
Update tiny11maker.ps1 - error handling param
error handling for param as we will later make the script agnostic to execution on OSDrive / $env:systemdrive
2024-11-07 02:07:18 +01:00
Karl Wester-Ebbinghaus
a5a4d97994
Update tiny11maker.ps1
fixed typo -ScratchDirectory (2)
2024-11-07 00:45:53 +01:00
Karl Wester-Ebbinghaus
d53ba61bd4
Update tiny11maker.ps1
typo -ScratchDirectory
2024-11-07 00:42:52 +01:00
Karl Wester-Ebbinghaus
3ef0c7efd9
Update tiny11maker.ps1
small corrections
2024-11-07 00:27:04 +01:00
Karl Wester-Ebbinghaus
bba078c34b
Update tiny11maker.ps1 - use dism with PowerShell commands
The idea of the release of this project is using PowerShell instead of commandline in the previous version, which is a great move and make it easier to maintain and read.

For sake of easier syntax and readability I have attempted using PowerShell commandlets for dism.


There are few remaining areas that need to be reworked (invoking dism.exe) to become fully consistent.
2024-11-07 00:25:16 +01:00
qtqgyt
1fe45e2e80
Update README.md 2024-11-03 12:22:50 -07:00
NTDEV
233b6b0fc4
Merge pull request #246 from Kichura/bitlocker
Disable device encryption by default
2024-10-12 18:07:49 +03:00
Kichura
5153812f23
Disable device encryption by default. 2024-09-27 23:03:21 +02:00
NTDEV
48714d253f
Merge pull request #197 from ntdevlabs/experimental
replace max compression with recovery compression
2024-05-21 23:34:35 +03:00
NTDEV
7ec6a7c253
replace max compression with recovery compression 2024-05-21 23:34:02 +03:00
NTDEV
9d9e51758a
Delete oscdimg.exe
There is no need for it since it downloads it on the fly now.
2024-05-20 21:11:14 +03:00
NTDEV
e51044f5af
Merge pull request #195 from ntdevlabs/experimental
Add oscdimg downloader
2024-05-20 21:06:40 +03:00
NTDEV
af2e6159d0
Add files via upload 2024-05-20 21:04:18 +03:00
NTDEV
eeb3c580e2
Added oscdimg downloader 2024-05-20 21:02:09 +03:00
NTDEV
427e6af437
Merge pull request #194 from rcmaehl/patch-1
Implement #183
2024-05-20 20:48:39 +03:00
Robert C. Maehl
fb59b449b2
Implement #183
Allow ScratchDisk parameter
2024-05-19 18:22:36 -04:00
NTDEV
cd8b9a74f4
Merge pull request #191 from chinmoykr/patch-1
Update README.md
2024-05-16 23:36:31 +03:00
chinmoykr
27a7f54e6a
Update README.md 2024-05-16 11:49:20 +05:30
NTDEV
8f43660267
Merge pull request #182 from ntdevlabs/revert-173-powershell_dism
Revert "Use PowerShell DISM cmdlets"
2024-05-09 01:30:12 +03:00
NTDEV
e618386dbd
Revert "Use PowerShell DISM cmdlets" 2024-05-09 01:29:55 +03:00
NTDEV
47ef9128b8
Create FUNDING.yml 2024-05-07 00:00:40 +03:00
NTDEV
f762e66aff
Merge pull request #173 from Ziron/powershell_dism
Use PowerShell DISM cmdlets
2024-05-06 23:53:52 +03:00
NTDEV
5dc7bdce49
Update README.md 2024-05-06 20:28:23 +03:00
NTDEV
218e141897
Introducing tiny11 core builder! 2024-05-06 19:59:43 +03:00
NTDEV
08eb2ff741
Update README.md 2024-05-04 18:12:58 +03:00
Sebastian Gustavsson
e8327ffa5f Use PowerShell DISM cmdlets 2024-05-03 15:02:54 +02:00
NTDEV
d33975d91b
Merge pull request #166 from Elrondo46/patch-1
Disable bing search in Start Menu
2024-05-02 13:32:21 +03:00
Elrondo46
d475687923
Disable bing search in Start Menu 2024-05-02 10:56:55 +02:00
NTDEV
d014d0119e
more lang-agnostic admin 2024-05-02 02:30:41 +03:00
NTDEV
8158c07cd9
language-agnostic admin icacls 2024-05-02 01:51:15 +03:00
NTDEV
fd1aa7dd61
ESD support, cleans Edge, fixes logging
This new release of tiny11 builder enables the ability to use images that has ESD files instead of the standard WIM. It also suppresses some of the output, making it a bit easier to track what is going on.
It also cleans up the last remains of Edge! Last, but not least, it fixes an issue with logging.
2024-05-01 23:40:33 +03:00
NTDEV
dbaa1db7a9
Merge pull request #141 from eugenesan/main
Add support for system ADK, Logging and Debug
2024-04-30 02:15:03 +03:00
Eugene San (eugenesan)
501e10c1ad Add support for system ADK, Logging and Debug 2024-04-29 15:35:08 -07:00
NTDEV
93eb664e56
Update README.md 2024-04-29 20:03:00 +03:00
NTDEV
dcb2c27332
tiny11 builder v04-29-24
Added telemetry disabling features.
2024-04-29 19:59:03 +03:00
NTDEV
77c74f524d
Merge pull request #140 from bwRavencl/english-dism
Fixes #136 - add `/English` to `dism` invocations
2024-04-25 20:46:45 +03:00
NTDEV
b277eb1019
Merge pull request #148 from Flickza/patch-2
Update README.md
2024-04-24 16:22:58 +03:00
Adel Johan Holm Gundersen
aa81dfc0d4
Update README.md 2024-04-24 14:57:12 +02:00
Matteo Hausner
98014c0b2a Fixes #136 - add /English to dism invocations
This ensures that the output of the `dism` command is in the expected
language, which is especially important if it gets parsed afterwards.
2024-04-24 00:34:03 +02:00
NTDEV
a543bd256d
Update README.md 2024-04-23 20:41:48 +03:00
NTDEV
63b44e4e03
Update README.md 2024-04-23 20:40:59 +03:00
NTDEV
4bc8256469
Update README.md 2024-04-23 20:40:33 +03:00
NTDEV
7edad858a8
Update README.md 2024-04-23 20:40:09 +03:00
NTDEV
ef962c2885
Update README.md 2024-04-23 20:39:45 +03:00
NTDEV
d4ae03fe49
Update README.md 2024-04-23 20:39:21 +03:00
NTDEV
4953ad860b
Update README.md 2024-04-23 20:38:58 +03:00
NTDEV
62db46658f
Update README.md 2024-04-23 20:17:42 +03:00
NTDEV
c91daeadaf
Merge pull request #135 from szepeviktor/indent4
Indent with 4 spaces
2024-04-22 12:35:17 +03:00
Viktor Szépe
643b85f5a6 Revert to DOS lineends 2024-04-22 08:46:10 +00:00
Viktor Szépe
d2a50a9d69 Use a real list in the README 2024-04-22 08:41:31 +00:00
Viktor Szépe
beab8214d5 Indent with 4 spaces 2024-04-22 08:40:16 +00:00
NTDEV
3c72acf1f1
Added tiny11 builder rewritten in PowerShell 2024-04-21 03:02:55 +03:00
NTDEV
c2679204e0
Update README.md 2024-04-21 03:01:25 +03:00
NTDEV
491145ce4c
Update README.md 2024-04-21 00:00:39 +03:00
NTDEV
de24916ffc
Update README.md 2024-04-20 23:58:23 +03:00
NTDEV
c7001dc2d2
Update README.md 2024-04-20 23:51:16 +03:00
NTDEV
6ce347e6f9
Delete tiny11 creator.bat
Legacy - Replaced by the PowerShell script
2024-04-20 23:44:47 +03:00
NTDEV
78efe85975
Delete tiny11 creator 25300.bat
Legacy - replaced by the PowerShell script
2024-04-20 23:44:22 +03:00
NTDEV
f0a96c7eb3
Delete tiny11 creator 22621.525.bat
Legacy - replaced by the PowerShell script
2024-04-20 23:44:00 +03:00
9 changed files with 718 additions and 787 deletions

5
.github/FUNDING.yml vendored Normal file
View file

@ -0,0 +1,5 @@
github: [0n1cOn3]
# Add custom links to support your work
custom: ['https://paypal.me/StefanKuny']

22
Dockerfile Normal file
View file

@ -0,0 +1,22 @@
# Use Windows Server Core as base image
FROM mcr.microsoft.com/windows/servercore:ltsc2022
# Define environment variables matching script paths
ENV ISO_MOUNT="C:\\ISOMount" `
OUTPUT_PATH="C:\\Tiny11_Output"
# Create necessary directories
RUN mkdir $ISO_MOUNT $OUTPUT_PATH
# Copy the PowerShell script into the container
COPY install_tiny11.ps1 C:\install_tiny11.ps1
# Set the working directory
WORKDIR C:\
# Set execution policy for scripts
SHELL ["powershell", "-Command"]
RUN Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Force
# Define entrypoint for running the script
ENTRYPOINT ["powershell.exe", "-File", "C:\\install_tiny11.ps1", "-OutputPath", "C:\\Tiny11_Output"]

581
Elevenbuilder.ps1 Normal file
View file

@ -0,0 +1,581 @@
<#
.SYNOPSIS
Tiny11 Image Creator Full Workflow (ISO Download, Mount, Customization, and ISO Creation)
.DESCRIPTION
This script uses DISM and other tools to create a customized Windows 11 image.
It now supports obtaining the Windows 11 ISO from a user-supplied path or by autodownloading
(using massgrave.dev as the source) if no ISO is provided. The ISO is then mounted and assigned
a free drive letter. The script then copies installation files, processes install.wim and boot.wim,
applies registry tweaks and removals, and finally creates an ISO using oscdimg.exe.
.PARAMETER ScratchDisk
A drive letter (e.g. "D") or path where the working files will be stored.
.PARAMETER ISOPath
(Optional) Full path to a Windows 11 ISO file. If not provided, the script will prompt for
the desired language and autodownload the ISO.
.PARAMETER Language
(Optional) Desired language code for the ISO download (e.g. "en-US", "de-DE"). Only used if ISOPath is not provided.
.NOTES
- This script requires administrative privileges.
- It assumes that your original workflow (registry tweaks, application removals, etc.) must remain intact.
- Some API endpoints (for downloading the ISO) are hypothetical and may need adjustment.
#>
param (
[ValidatePattern('^[c-zC-Z]$')]
[string]$ScratchDisk,
[string]$ISOPath, # Full path to a Windows 11 ISO (optional)
[string]$Language # Desired language code (e.g., "en-US", "de-DE")
)
#region Helper Functions (ISO download and mount)
function Get-Win11DownloadLink {
<#
.SYNOPSIS
Queries the API (via massgrave.dev) for the proper ISO download link.
.PARAMETER Language
The desired language code.
.OUTPUTS
The download URL as a string.
#>
param(
[Parameter(Mandatory = $true)]
[string]$Language
)
# Adjust the endpoint and parameters as required.
$apiBase = "https://api.gravesoft.dev/msdl/"
$endpoint = "getDownloadLink" # Hypothetical endpoint.
$url = "$apiBase$endpoint?language=$Language"
Write-Host "Querying download link for Windows 11 ISO for language: $Language" -ForegroundColor Cyan
try {
$response = Invoke-RestMethod -Uri $url -Method Get
if ($response -and $response.downloadUrl) {
Write-Host "Download URL obtained: $($response.downloadUrl)" -ForegroundColor Green
return $response.downloadUrl
}
else {
Write-Error "API did not return a valid download URL."
return $null
}
}
catch {
Write-Error "Error calling the download API: $_"
return $null
}
}
function Get-Windows11ISO {
<#
.SYNOPSIS
Returns the path to a Windows 11 ISO. If a valid ISOPath is provided, that file is used.
Otherwise, prompts (or uses the provided language) and downloads the ISO.
.PARAMETER ISOPath
User-supplied ISO path.
.PARAMETER Language
Desired language code.
.OUTPUTS
The full path to the Windows 11 ISO.
#>
param(
[string]$ISOPath,
[string]$Language
)
# Use provided ISO if valid
if ($ISOPath -and (Test-Path $ISOPath -PathType Leaf)) {
Write-Host "Using provided ISO: $ISOPath" -ForegroundColor Green
return $ISOPath
}
# If no ISO path, prompt for language (if not provided)
if (-not $Language) {
$Language = Read-Host "Enter your desired Windows 11 language (e.g., en-US, de-DE)"
}
$downloadLink = Get-Win11DownloadLink -Language $Language
if (-not $downloadLink) {
Write-Error "Could not retrieve a valid download link. Exiting."
exit 1
}
$DownloadPath = "$env:TEMP\Windows11_$Language.iso"
Write-Host "Downloading Windows 11 ISO from $downloadLink ..." -ForegroundColor Cyan
try {
Invoke-WebRequest -Uri $downloadLink -OutFile $DownloadPath
Write-Host "Download complete: $DownloadPath" -ForegroundColor Green
return $DownloadPath
}
catch {
Write-Error "Failed to download the ISO: $_"
exit 1
}
}
function Mount-ISOAndAssignDriveLetter {
<#
.SYNOPSIS
Mounts an ISO image and assigns a free drive letter if none is already assigned.
.PARAMETER ISOPath
The full path to the ISO file.
.OUTPUTS
The drive letter (e.g., "E:") where the ISO is mounted.
#>
param(
[Parameter(Mandatory = $true)]
[string]$ISOPath
)
if (-not (Test-Path $ISOPath)) {
Write-Error "The ISO file '$ISOPath' does not exist."
return
}
Write-Host "Mounting ISO image: $ISOPath" -ForegroundColor Cyan
$mountedImage = Mount-DiskImage -ImagePath $ISOPath -PassThru
if (-not $mountedImage) {
Write-Error "Failed to mount ISO image."
return
}
Start-Sleep -Seconds 3 # Wait for the volume to become available
$diskImage = Get-DiskImage -ImagePath $ISOPath
if (-not $diskImage) {
Write-Error "Unable to retrieve disk image information."
return
}
$disk = $diskImage | Get-Disk
if (-not $disk) {
Write-Error "Unable to retrieve disk information for the mounted image."
return
}
$diskNumber = $disk.Number
# Retrieve the first partition (most ISOs contain a single partition)
$partition = Get-Partition -DiskNumber $diskNumber | Select-Object -First 1
if (-not $partition) {
Write-Error "No partition found on the mounted ISO."
return
}
# If no drive letter is assigned, choose a free one (from C: to Z:)
if (-not $partition.DriveLetter) {
$freeLetters = [char[]](67..90) | ForEach-Object { [char]$_ }
$usedLetters = (Get-Volume | Where-Object { $_.DriveLetter } | Select-Object -ExpandProperty DriveLetter)
$availableLetters = $freeLetters | Where-Object { $usedLetters -notcontains $_ }
if ($availableLetters.Count -eq 0) {
Write-Error "No free drive letters available."
return
}
$freeLetter = $availableLetters | Select-Object -First 1
Write-Host "Assigning drive letter '$freeLetter' to the mounted ISO." -ForegroundColor Yellow
Set-Partition -DiskNumber $diskNumber -PartitionNumber $partition.PartitionNumber -NewDriveLetter $freeLetter
$driveLetter = "$freeLetter`:"
}
else {
$driveLetter = "$($partition.DriveLetter):"
}
Write-Host "ISO mounted at drive letter: $driveLetter" -ForegroundColor Green
return $driveLetter
}
#endregion Helper Functions
#region Environment Setup
function Setup-Environment {
<#
.SYNOPSIS
Performs pre-flight checks, sets the scratch disk, adjusts execution policy,
ensures admin rights, starts logging, and creates necessary directories.
#>
# Set ScratchDisk (if not provided, use the script folder)
if (-not $ScratchDisk) {
$global:ScratchDisk = $PSScriptRoot.TrimEnd('\')
} else {
$global:ScratchDisk = "$ScratchDisk`:" # Append colon if needed.
}
Write-Output "Scratch disk set to $global:ScratchDisk"
# Check and adjust execution policy
if ((Get-ExecutionPolicy) -eq 'Restricted') {
Write-Host "Your current PowerShell Execution Policy is 'Restricted'. Changing it to 'RemoteSigned'..."
Set-ExecutionPolicy RemoteSigned -Scope CurrentUser -Confirm:$false
}
# Ensure script is running as administrator
$adminRole = [System.Security.Principal.WindowsBuiltInRole]::Administrator
$principal = New-Object System.Security.Principal.WindowsPrincipal([System.Security.Principal.WindowsIdentity]::GetCurrent())
if (-not $principal.IsInRole($adminRole)) {
Write-Host "Restarting the script with elevated privileges..."
$arguments = "-NoProfile -ExecutionPolicy Bypass -File `"$PSCommandPath`""
Start-Process powershell -Verb RunAs -ArgumentList $arguments
exit
}
# Start logging and set window title
Start-Transcript -Path "$global:ScratchDisk\tiny11.log"
$Host.UI.RawUI.WindowTitle = "Tiny11 Image Creator"
Clear-Host
Write-Host "Welcome to the Tiny11 Image Creator! Release: 05-06-24" -ForegroundColor Cyan
# Create required directories
$global:tiny11Folder = Join-Path $global:ScratchDisk "tiny11"
$global:sourcesFolder = Join-Path $global:tiny11Folder "sources"
$global:mountPath = Join-Path $global:ScratchDisk "scratchdir"
New-Item -ItemType Directory -Force -Path $global:sourcesFolder | Out-Null
New-Item -ItemType Directory -Force -Path $global:mountPath | Out-Null
}
#endregion Environment Setup
#region Obtain & Mount Installation Media
function Get-InstallationMedia {
<#
.SYNOPSIS
Obtains the Windows 11 ISO (using a provided path or by downloading it) and mounts it.
.OUTPUTS
The drive letter where the installation media is mounted.
#>
# Get the ISO (download if necessary)
$global:win11ISO = Get-Windows11ISO -ISOPath $ISOPath -Language $Language
if (-not $global:win11ISO) {
Write-Error "Failed to obtain a Windows 11 ISO. Exiting."
exit
}
# Mount the ISO and retrieve the drive letter
$mediaDrive = Mount-ISOAndAssignDriveLetter -ISOPath $global:win11ISO
if (-not $mediaDrive) {
Write-Error "Failed to mount the Windows 11 ISO. Exiting."
exit
}
Write-Output "Installation media mounted at: $mediaDrive"
return $mediaDrive
}
#endregion Obtain & Mount Installation Media
#region Process install.wim Image
function Process-InstallImage {
<#
.SYNOPSIS
Processes the Windows installation image (install.wim). This includes:
- Validating that the necessary installation files exist (or converting install.esd)
- Copying installation files from the installation media to the working folder
- Mounting the install.wim, gathering image information, applying customizations,
removing apps, tweaking registries, and finally unmounting the image.
#>
param(
[string]$DriveLetter # Installation media drive letter
)
# Validate Windows installation files
if ((Test-Path "$DriveLetter\sources\boot.wim") -eq $false -or (Test-Path "$DriveLetter\sources\install.wim") -eq $false) {
if (Test-Path "$DriveLetter\sources\install.esd") {
Write-Host "Found install.esd, converting to install.wim..."
Get-WindowsImage -ImagePath "$DriveLetter\sources\install.esd"
$index = Read-Host "Please enter the image index to convert from install.esd"
Write-Host "Converting install.esd to install.wim. This may take a while..."
Export-WindowsImage -SourceImagePath "$DriveLetter\sources\install.esd" `
-SourceIndex $index `
-DestinationImagePath "$global:ScratchDisk\tiny11\sources\install.wim" `
-CompressionType Maximum -CheckIntegrity
} else {
Write-Host "Cannot find Windows OS installation files on the installation media."
exit
}
}
else {
Write-Host "Copying Windows installation files from $DriveLetter..."
Copy-Item -Path "$DriveLetter\*" -Destination "$global:tiny11Folder" -Recurse -Force | Out-Null
# Remove install.esd if present
Set-ItemProperty -Path "$global:tiny11Folder\sources\install.esd" -Name IsReadOnly -Value $false -ErrorAction SilentlyContinue
Remove-Item "$global:tiny11Folder\sources\install.esd" -ErrorAction SilentlyContinue
Write-Host "Copy complete!"
}
Start-Sleep -Seconds 2
Clear-Host
Write-Host "Retrieving image information from install.wim..."
Get-WindowsImage -ImagePath (Join-Path $global:sourcesFolder "install.wim")
$index = Read-Host "Please enter the desired image index"
Write-Host "Mounting install.wim image. This may take a while..."
$global:wimFilePath = Join-Path $global:sourcesFolder "install.wim"
& takeown "/F" $global:wimFilePath
& icacls $global:wimFilePath "/grant" "$($adminGroup.Value):(F)"
try {
Set-ItemProperty -Path $global:wimFilePath -Name IsReadOnly -Value $false -ErrorAction Stop
} catch {
# Suppress errors
}
New-Item -ItemType Directory -Force -Path $global:mountPath > $null
Mount-WindowsImage -ImagePath $global:wimFilePath -Index $index -Path $global:mountPath
# Retrieve system UI language from the mounted image
$imageIntl = & dism /English /Get-Intl "/Image:$global:mountPath"
$languageLine = $imageIntl -split '\n' | Where-Object { $_ -match 'Default system UI language : ([a-zA-Z]{2}-[a-zA-Z]{2})' }
if ($languageLine) {
$languageCode = $Matches[1]
Write-Host "Default system UI language code: $languageCode"
} else {
Write-Host "Default system UI language code not found."
}
# Retrieve architecture information from the image
$imageInfo = & dism /English /Get-WimInfo "/wimFile:$global:sourcesFolder\install.wim" "/index:$index"
$lines = $imageInfo -split '\r?\n'
foreach ($line in $lines) {
if ($line -like '*Architecture : *') {
$architecture = $line -replace 'Architecture : ',''
if ($architecture -eq 'x64') {
$architecture = 'amd64'
}
Write-Host "Architecture: $architecture"
break
}
}
if (-not $architecture) {
Write-Host "Architecture information not found."
}
Write-Host "Install image mounted. Proceeding with application removals and customizations..."
# Remove unwanted applications (bloatware) via DISM
$packages = & dism /English "/image:$global:mountPath" '/Get-ProvisionedAppxPackages' |
ForEach-Object {
if ($_ -match 'PackageName : (.*)') {
$matches[1]
}
}
$packagePrefixes = 'Clipchamp.Clipchamp_', 'Microsoft.BingNews_', 'Microsoft.BingWeather_', 'Microsoft.GamingApp_', 'Microsoft.GetHelp_', 'Microsoft.Getstarted_', 'Microsoft.MicrosoftOfficeHub_', 'Microsoft.MicrosoftSolitaireCollection_', 'Microsoft.People_', 'Microsoft.PowerAutomateDesktop_', 'Microsoft.Todos_', 'Microsoft.WindowsAlarms_', 'microsoft.windowscommunicationsapps_', 'Microsoft.WindowsFeedbackHub_', 'Microsoft.WindowsMaps_', 'Microsoft.WindowsSoundRecorder_', 'Microsoft.Xbox.TCUI_', 'Microsoft.XboxGamingOverlay_', 'Microsoft.XboxGameOverlay_', 'Microsoft.XboxSpeechToTextOverlay_', 'Microsoft.YourPhone_', 'Microsoft.ZuneMusic_', 'Microsoft.ZuneVideo_', 'MicrosoftCorporationII.MicrosoftFamily_', 'MicrosoftCorporationII.QuickAssist_', 'MicrosoftTeams_', 'Microsoft.549981C3F5F10_'
$packagesToRemove = $packages | Where-Object {
$packageName = $_
$packagePrefixes -contains ($packagePrefixes | Where-Object { $packageName -like "$_*" })
}
foreach ($package in $packagesToRemove) {
& dism /English "/image:$global:mountPath" '/Remove-ProvisionedAppxPackage' "/PackageName:$package"
}
# Remove Microsoft Edge and its components
Write-Host "Removing Microsoft Edge..."
Remove-Item -Path "$global:mountPath\Program Files (x86)\Microsoft\Edge" -Recurse -Force -ErrorAction SilentlyContinue
Remove-Item -Path "$global:mountPath\Program Files (x86)\Microsoft\EdgeUpdate" -Recurse -Force -ErrorAction SilentlyContinue
Remove-Item -Path "$global:mountPath\Program Files (x86)\Microsoft\EdgeCore" -Recurse -Force -ErrorAction SilentlyContinue
if ($architecture -eq 'amd64') {
$folderPath = Get-ChildItem -Path "$global:mountPath\Windows\WinSxS" -Filter "amd64_microsoft-edge-webview_31bf3856ad364e35*" -Directory | Select-Object -ExpandProperty FullName
if ($folderPath) {
& takeown '/f' $folderPath '/r' | Out-Null
& icacls $folderPath "/grant" "$($adminGroup.Value):(F)" '/T' '/C' | Out-Null
Remove-Item -Path $folderPath -Recurse -Force | Out-Null
} else {
Write-Host "Edge WebView folder not found."
}
}
elseif ($architecture -eq 'arm64') {
$folderPath = Get-ChildItem -Path "$global:mountPath\Windows\WinSxS" -Filter "arm64_microsoft-edge-webview_31bf3856ad364e35*" -Directory | Select-Object -ExpandProperty FullName
if ($folderPath) {
& takeown '/f' $folderPath '/r' | Out-Null
& icacls $folderPath "/grant" "$($adminGroup.Value):(F)" '/T' '/C' | Out-Null
Remove-Item -Path $folderPath -Recurse -Force | Out-Null
} else {
Write-Host "Edge WebView folder not found."
}
}
& takeown '/f' "$global:mountPath\Windows\System32\Microsoft-Edge-Webview" '/r' | Out-Null
& icacls "$global:mountPath\Windows\System32\Microsoft-Edge-Webview" '/grant' "$($adminGroup.Value):(F)" '/T' '/C' | Out-Null
Remove-Item -Path "$global:mountPath\Windows\System32\Microsoft-Edge-Webview" -Recurse -Force | Out-Null
# Remove OneDrive
Write-Host "Removing OneDrive..."
& takeown '/f' "$global:mountPath\Windows\System32\OneDriveSetup.exe" | Out-Null
& icacls "$global:mountPath\Windows\System32\OneDriveSetup.exe" '/grant' "$($adminGroup.Value):(F)" '/T' '/C' | Out-Null
Remove-Item -Path "$global:mountPath\Windows\System32\OneDriveSetup.exe" -Force | Out-Null
Write-Host "Application removal complete!"
Start-Sleep -Seconds 2
Clear-Host
# Load registry hives from the mounted image and apply tweaks
Write-Host "Loading registry hives from the mounted image..."
reg load HKLM\zCOMPONENTS "$global:mountPath\Windows\System32\config\COMPONENTS" | Out-Null
reg load HKLM\zDEFAULT "$global:mountPath\Windows\System32\config\default" | Out-Null
reg load HKLM\zNTUSER "$global:mountPath\Users\Default\ntuser.dat" | Out-Null
reg load HKLM\zSOFTWARE "$global:mountPath\Windows\System32\config\SOFTWARE" | Out-Null
reg load HKLM\zSYSTEM "$global:mountPath\Windows\System32\config\SYSTEM" | Out-Null
Write-Host "Applying registry tweaks to bypass system requirements..."
& reg add 'HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache' '/v' 'SV1' '/t' 'REG_DWORD' '/d' '0' '/f' | Out-Null
& reg add 'HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache' '/v' 'SV2' '/t' 'REG_DWORD' '/d' '0' '/f' | Out-Null
& reg add 'HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache' '/v' 'SV1' '/t' 'REG_DWORD' '/d' '0' '/f' | Out-Null
& reg add 'HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache' '/v' 'SV2' '/t' 'REG_DWORD' '/d' '0' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\LabConfig' '/v' 'BypassCPUCheck' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\LabConfig' '/v' 'BypassRAMCheck' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\LabConfig' '/v' 'BypassSecureBootCheck' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\LabConfig' '/v' 'BypassStorageCheck' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\LabConfig' '/v' 'BypassTPMCheck' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\MoSetup' '/v' 'AllowUpgradesWithUnsupportedTPMOrCPU' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
Write-Host "Registry tweaks complete. Unloading registry hives..."
reg unload HKLM\zCOMPONENTS | Out-Null
reg unload HKLM\zDEFAULT | Out-Null
reg unload HKLM\zNTUSER | Out-Null
reg unload HKLM\zSOFTWARE | Out-Null
reg unload HKLM\zSYSTEM | Out-Null
Write-Host "Performing component cleanup on the image..."
Repair-WindowsImage -Path $global:mountPath -StartComponentCleanup -ResetBase
Write-Host "Unmounting install.wim image (saving changes)..."
Dismount-WindowsImage -Path $global:mountPath -Save
Clear-Host
Write-Host "Exporting updated install.wim..."
Export-WindowsImage -SourceImagePath (Join-Path $global:sourcesFolder "install.wim") -SourceIndex $index `
-DestinationImagePath (Join-Path $global:sourcesFolder "install2.wim") -CompressionType Fast
Remove-Item -Path (Join-Path $global:sourcesFolder "install.wim") -Force | Out-Null
Rename-Item -Path (Join-Path $global:sourcesFolder "install2.wim") -NewName "install.wim" -Force | Out-Null
Write-Host "Install image processing complete. Proceeding with boot.wim..."
}
#endregion Process install.wim Image
#region Process boot.wim Image
function Process-BootImage {
<#
.SYNOPSIS
Processes the boot image (boot.wim). This includes mounting the boot image,
applying necessary tweaks (if any), and then unmounting the image.
#>
Write-Host "Mounting boot.wim image..."
$global:wimFilePath = Join-Path $global:sourcesFolder "boot.wim"
& takeown "/F" $global:wimFilePath | Out-Null
& icacls $global:wimFilePath "/grant" "$($adminGroup.Value):(F)" | Out-Null
Set-ItemProperty -Path $global:wimFilePath -Name IsReadOnly -Value $false
Mount-WindowsImage -ImagePath $global:wimFilePath -Index 2 -Path $global:mountPath
Write-Host "Boot image mounted. Loading registry from boot image..."
reg load HKLM\zCOMPONENTS "$global:mountPath\Windows\System32\config\COMPONENTS" | Out-Null
reg load HKLM\zDEFAULT "$global:mountPath\Windows\System32\config\default" | Out-Null
reg load HKLM\zNTUSER "$global:mountPath\Users\Default\ntuser.dat" | Out-Null
reg load HKLM\zSOFTWARE "$global:mountPath\Windows\System32\config\SOFTWARE" | Out-Null
reg load HKLM\zSYSTEM "$global:mountPath\Windows\System32\config\SYSTEM" | Out-Null
Write-Host "Applying tweaks to boot image registry..."
& reg add 'HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache' '/v' 'SV1' '/t' 'REG_DWORD' '/d' '0' '/f' | Out-Null
& reg add 'HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache' '/v' 'SV2' '/t' 'REG_DWORD' '/d' '0' '/f' | Out-Null
& reg add 'HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache' '/v' 'SV1' '/t' 'REG_DWORD' '/d' '0' '/f' | Out-Null
& reg add 'HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache' '/v' 'SV2' '/t' 'REG_DWORD' '/d' '0' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\LabConfig' '/v' 'BypassCPUCheck' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\LabConfig' '/v' 'BypassRAMCheck' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\LabConfig' '/v' 'BypassSecureBootCheck' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\LabConfig' '/v' 'BypassStorageCheck' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\LabConfig' '/v' 'BypassTPMCheck' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
& reg add 'HKLM\zSYSTEM\Setup\MoSetup' '/v' 'AllowUpgradesWithUnsupportedTPMOrCPU' '/t' 'REG_DWORD' '/d' '1' '/f' | Out-Null
Write-Host "Tweaks for boot image applied. Unloading registry hives..."
reg unload HKLM\zCOMPONENTS | Out-Null
reg unload HKLM\zDEFAULT | Out-Null
reg unload HKLM\zNTUSER | Out-Null
reg unload HKLM\zSOFTWARE | Out-Null
reg unload HKLM\zSYSTEM | Out-Null
Write-Host "Unmounting boot image (saving changes)..."
Dismount-WindowsImage -Path $global:mountPath -Save
}
#endregion Process boot.wim Image
#region Finalize ISO Creation
function Finalize-ISO {
<#
.SYNOPSIS
Uses oscdimg.exe to create the final Tiny11 ISO from the customized image.
#>
Write-Host "Copying unattended file for bypassing MS account on OOBE..."
Copy-Item -Path "$PSScriptRoot\autounattend.xml" -Destination "$global:tiny11Folder\autounattend.xml" -Force | Out-Null
Write-Host "Creating final ISO image..."
$ADKDepTools = "C:\Program Files (x86)\Windows Kits\10\Assessment and Deployment Kit\Deployment Tools\$hostarchitecture\Oscdimg"
$localOSCDIMGPath = "$PSScriptRoot\oscdimg.exe"
if ([System.IO.Directory]::Exists($ADKDepTools)) {
Write-Host "Using oscdimg.exe from the system ADK."
$OSCDIMG = Join-Path $ADKDepTools "oscdimg.exe"
} else {
Write-Host "ADK folder not found. Using bundled oscdimg.exe."
if (-not (Test-Path -Path $localOSCDIMGPath)) {
Write-Host "Downloading oscdimg.exe..."
$url = "https://msdl.microsoft.com/download/symbols/oscdimg.exe/3D44737265000/oscdimg.exe"
Invoke-WebRequest -Uri $url -OutFile $localOSCDIMGPath
if (-not (Test-Path $localOSCDIMGPath)) {
Write-Error "Failed to download oscdimg.exe."
exit 1
}
} else {
Write-Host "oscdimg.exe already exists locally."
}
$OSCDIMG = $localOSCDIMGPath
}
# Define boot data (adjust paths if necessary)
$bootData = "2#p0,e,b$global:tiny11Folder\boot\etfsboot.com#pEF,e,b$global:tiny11Folder\efi\microsoft\boot\efisys.bin"
$isoOutput = Join-Path $PSScriptRoot "tiny11.iso"
& "$OSCDIMG" '-m' '-o' '-u2' '-udfver102' "-bootdata:$bootData" "$global:tiny11Folder" "$isoOutput"
Write-Host "ISO creation complete: $isoOutput" -ForegroundColor Green
}
#endregion Finalize ISO Creation
#region Cleanup
function Cleanup-Environment {
<#
.SYNOPSIS
Cleans up temporary folders used during image processing.
#>
Write-Host "Performing cleanup..."
Remove-Item -Path "$global:tiny11Folder" -Recurse -Force -ErrorAction SilentlyContinue
Remove-Item -Path "$global:mountPath" -Recurse -Force -ErrorAction SilentlyContinue
Stop-Transcript
Write-Host "Cleanup complete."
}
#endregion Cleanup
#region Main Flow
function Main {
# Step 1: Setup environment (parameters, admin check, logging, directories)
Setup-Environment
# Step 2: Obtain and mount installation media (ISO)
$mediaDrive = Get-InstallationMedia
# Step 3: Process the install.wim image (copy files, convert ESD if needed, apply tweaks)
Process-InstallImage -DriveLetter $mediaDrive
# Step 4: Process the boot.wim image
Process-BootImage
# Step 5: Finalize ISO creation using oscdimg.exe
Finalize-ISO
# Step 6: Cleanup temporary folders and stop logging
Cleanup-Environment
Write-Host "Tiny11 image creation completed. Press Enter to exit."
Read-Host
exit
}
# Start the main flow
Main
#endregion Main Flow

126
README.md
View file

@ -1,60 +1,84 @@
# tiny11builder # ElevenBuilder
Scripts to build a trimmed-down Windows 11 image. To build a trimmed-down Windows 11 image.
This is a script to automate the build of a streamlined Windows 11 image, similar to tiny11. ElevenBuilder is a flexible solution - one script fits all. Also, it is a steppingstone for an even more fleshed-out solution.
My main goal is to use only Microsoft utilities like DISM, and nothing external. The only executable included is oscdimg.exe, which is provided in the Windows ADK and it is used to create bootable ISO images. Also included is an unattended answer file, which is used to bypass the MS account on OOBE and to deploy the image with the /compact flag.
It's open-source, so feel free to add or remove anything you want! Feedback is also much appreciated.
As of now, only build 22621.525 (the one that can be downloaded from the Microsoft website), 22621.1265 (the latest public build) and 25300 (latest Insider build as of now) are supported. You need to set the execution policy to Unrestricted, so that you can run the script.
If you haven't done this before, make sure to run:
Instructions: ```powershell
Set-ExecutionPolicy unrestricted
```
1. Download Windows 11 22621.1265 from UUPDump or 22621.525 or 25300 from the Microsoft website (<https://www.microsoft.com/software-download/windows11>) as administrator in PowerShell before running the script, otherwise it will not run.
2. Mount the downloaded ISO image using Windows Explorer.
3. For .1265, run tiny11 creator.bat as administrator. For .525 or 25300, use the aptly-named script (also as administrator).
4. Select the drive letter where the image is mounted (only the letter, no colon (:))
5. Select the SKU that you want the image to be based.
6. Sit back and relax :)
7. When the image is completed, you will see it in the folder where the script was extracted, with the name tiny11.iso
What is removed: This is a script has been created to automate the build of a streamlined Windows 11 Image, similar to tiny11.
Clipchamp, The main goal is to use only Microsoft utilities like DISM, and no utilities from external sources.
News, The only executable included is oscdimg.exe, which is provided in the Windows ADK and is used to create bootable ISO images.
Weather, Also included is an unattended answer file, which is used to bypass the Microsoft Account on OOBE and to deploy the image with the /compact flag.
Xbox (although Xbox Identity provider is still here, so it should be possible to be reinstalled with no issues),
GetHelp,
GetStarted,
Office Hub,
Solitaire,
PeopleApp,
PowerAutomate,
ToDo,
Alarms,
Mail and Calendar,
Feedback Hub,
Maps,
Sound Recorder,
Your Phone,
Media Player,
QuickAssist,
Internet Explorer,
LA57 support,
OCR for en-us,
Speech support,
TTS for en-us,
Media Player Legacy,
Tablet PC Math,
Wallpapers,
Edge,
OneDrive
Known issues: Instructions: (Needs to be rewritten - Consider as unstable/broken for the moment...)
1. Microsoft Teams (personal) and Cortana are still here. If you find a way to remove them before I find one, feel free to help! - Download Windows 11 from the Microsoft website: Microsoft Windows 11 Download
2. Although Edge is removed, the icon and a ghost of its taskbar pin are still available. Also, there are some remnants in the Settings. But the app in itself is deleted. - Mount the downloaded ISO image using Windows Explorer.
3. The script is rather inflexible, as in only the builds specified can be modified. This is because with each new build Microsoft also updates the inbox apps included. If one tries to use other builds, it will work with varying degrees of success, but some things like the removal of Edge and OneDrive as well as bypassing system requirements or other patches will always be applied. - Select the drive letter where the image is mounted (only the letter, no colon :)
4. Only en-us x64 is supported as of now. This can be easily fixable by the end user, just by replacing every instance of en-us with the language needed (like ro-RO and so on), and every x64 instance with arm64. - Select the SKU that you want the image to be based on.
- Sit back and relax :)
And that's pretty much it for now! When the image is completed, you will see it in the folder where the script was extracted, with the name tiny11.iso
Thanks for trying it and let me know how you like it!
What has been removed:
- Clipchamp
- News
- Weather
- Xbox (although Xbox Identity provider is still here, so it should be possible to reinstall it with no issues)
- GetHelp
- GetStarted
- Office Hub
- Solitaire
- PeopleApp
- PowerAutomate
- ToDo
- Alarms
- Mail and Calendar
- Feedback Hub
- Maps
- Sound Recorder
- Your Phone
- Media Player
- QuickAssist
- Internet Explorer
- Tablet PC Math
- Microsoft Edge
- Microsoft OneDrive
You will be asked during image creation if you want to enable .NET 3.5 support!
### Known Issues:
Edge remnants: Although Edge is removed, some remnants exist in the Settings. However, the app itself is deleted. You can install any browser using WinGet (after updating the app using the Microsoft Store). If you want Edge, Copilot, and Web Search back, simply install Edge using:
```powershell
winget install edge
```
**Note:** You might need to update Winget before being able to install any apps via Microsoft Store.
Outlook and Dev Home might reappear after some time due to Windows Updates.
ARM64 error message: If using this script on ARM64, you might see an error while running the script. This happens because the ARM64 image doesn't have OneDriveSetup.exe included in the System32 folder.
### Features to be implemented:
- More ad suppression
- Improved language and architecture detection
- More flexibility in what to keep and what to delete
- Maybe a GUI???
### Disclaimer
Microsoft and there Products are registered trademarks.
It's open-source, so feel free to add or remove anything you want! Feedback is also much appreciated! :-)

View file

@ -1,37 +1,37 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<unattend xmlns="urn:schemas-microsoft-com:unattend"> <unattend xmlns="urn:schemas-microsoft-com:unattend">
<settings pass="oobeSystem"> <settings pass="oobeSystem">
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <component xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
<OOBE> <OOBE>
<HideOnlineAccountScreens>true</HideOnlineAccountScreens> <HideOnlineAccountScreens>true</HideOnlineAccountScreens>
</OOBE> </OOBE>
</component> </component>
</settings> </settings>
<component name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <component xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" name="Microsoft-Windows-Shell-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
<ConfigureChatAutoInstall>false</ConfigureChatAutoInstall> <ConfigureChatAutoInstall>false</ConfigureChatAutoInstall>
</component> </component>
<settings pass="windowsPE"> <settings pass="windowsPE">
<component name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS" xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"> <component xmlns:wcm="http://schemas.microsoft.com/WMIConfig/2002/State" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" name="Microsoft-Windows-Setup" processorArchitecture="amd64" publicKeyToken="31bf3856ad364e35" language="neutral" versionScope="nonSxS">
<DynamicUpdate> <DynamicUpdate>
<WillShowUI>OnError</WillShowUI> <WillShowUI>OnError</WillShowUI>
</DynamicUpdate> </DynamicUpdate>
<ImageInstall> <ImageInstall>
<OSImage> <OSImage>
<Compact>true</Compact> <Compact>true</Compact>
<WillShowUI>OnError</WillShowUI> <WillShowUI>OnError</WillShowUI>
<InstallFrom> <InstallFrom>
<MetaData wcm:action="add"> <MetaData wcm:action="add">
<Key>/IMAGE/INDEX</Key> <Key>/IMAGE/INDEX</Key>
<Value>1</Value> <Value>1</Value>
</MetaData> </MetaData>
</InstallFrom> </InstallFrom>
</OSImage> </OSImage>
</ImageInstall> </ImageInstall>
<UserData> <UserData>
<ProductKey> <ProductKey>
<Key></Key> <Key/>
</ProductKey> </ProductKey>
</UserData> </UserData>
</component> </component>
</settings> </settings>
</unattend> </unattend>

Binary file not shown.

View file

@ -1,234 +0,0 @@
@echo off
setlocal EnableExtensions EnableDelayedExpansion
title tiny11 builder alpha
echo Welcome to the tiny11 image creator!
timeout /t 3 /nobreak > nul
cls
set DriveLetter=
set /p DriveLetter=Please enter the drive letter for the Windows 11 image:
set "DriveLetter=%DriveLetter%:"
echo.
if not exist "%DriveLetter%\sources\boot.wim" (
echo.Can't find Windows OS Installation files in the specified Drive Letter..
echo.
echo.Please enter the correct DVD Drive Letter..
goto :Stop
)
if not exist "%DriveLetter%\sources\install.wim" (
echo.Can't find Windows OS Installation files in the specified Drive Letter..
echo.
echo.Please enter the correct DVD Drive Letter..
goto :Stop
)
md c:\tiny11
echo Copying Windows image...
xcopy.exe /E /I /H /R /Y /J %DriveLetter% c:\tiny11 >nul
echo Copy complete!
sleep 2
cls
echo Getting image information:
dism /Get-WimInfo /wimfile:c:\tiny11\sources\install.wim
set index=
set /p index=Please enter the image index:
set "index=%index%"
echo Mounting Windows image. This may take a while.
echo.
md c:\scratchdir
dism /mount-image /imagefile:c:\tiny11\sources\install.wim /index:%index% /mountdir:c:\scratchdir
echo Mounting complete! Performing removal of applications...
echo Removing Clipchamp...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Clipchamp.Clipchamp_2.2.8.0_neutral_~_yxz26nhyzhsrt
echo Removing News...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.BingNews_4.2.27001.0_neutral_~_8wekyb3d8bbwe
echo Removing Weather...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.BingWeather_4.53.33420.0_neutral_~_8wekyb3d8bbwe
echo Removing Xbox...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.GamingApp_2021.427.138.0_neutral_~_8wekyb3d8bbwe
echo Removing GetHelp...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.GetHelp_10.2201.421.0_neutral_~_8wekyb3d8bbwe
echo Removing GetStarted...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.Getstarted_2021.2204.1.0_neutral_~_8wekyb3d8bbwe
echo Removing Office Hub...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.MicrosoftOfficeHub_18.2204.1141.0_neutral_~_8wekyb3d8bbwe
echo Removing Solitaire...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.MicrosoftSolitaireCollection_4.12.3171.0_neutral_~_8wekyb3d8bbwe
echo Removing PeopleApp...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.People_2020.901.1724.0_neutral_~_8wekyb3d8bbwe
echo Removing PowerAutomate...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.PowerAutomateDesktop_10.0.3735.0_neutral_~_8wekyb3d8bbwe
echo Removing ToDo...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.Todos_2.54.42772.0_neutral_~_8wekyb3d8bbwe
echo Removing Alarms...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsAlarms_2022.2202.24.0_neutral_~_8wekyb3d8bbwe
echo Removing Mail...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:microsoft.windowscommunicationsapps_16005.14326.20544.0_neutral_~_8wekyb3d8bbwe
echo Removing Feedback Hub...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsFeedbackHub_2022.106.2230.0_neutral_~_8wekyb3d8bbwe
echo Removing Maps...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsMaps_2022.2202.6.0_neutral_~_8wekyb3d8bbwe
echo Removing Sound Recorder...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsSoundRecorder_2021.2103.28.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxTCUI...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.Xbox.TCUI_1.23.28004.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxGamingOverlay...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.XboxGamingOverlay_2.622.3232.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxGameOverlay...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.XboxGameOverlay_1.47.2385.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxSpeechToTextOverlay...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.XboxSpeechToTextOverlay_1.17.29001.0_neutral_~_8wekyb3d8bbwe
echo Removing Your Phone...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.YourPhone_1.22022.147.0_neutral_~_8wekyb3d8bbwe
echo Removing Music...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.ZuneMusic_11.2202.46.0_neutral_~_8wekyb3d8bbwe
echo Removing Video...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.ZuneVideo_2019.22020.10021.0_neutral_~_8wekyb3d8bbwe
echo Removing Family...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:MicrosoftCorporationII.MicrosoftFamily_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing QuickAssist...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:MicrosoftCorporationII.QuickAssist_2022.414.1758.0_neutral_~_8wekyb3d8bbwe
echo Removing Teams...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:MicrosoftTeams_23002.403.1788.1930_x64__8wekyb3d8bbwe
echo Removing Cortana...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.549981C3F5F10_4.2204.13303.0_neutral_~_8wekyb3d8bbwe
echo Removing of system apps complete! Now proceeding to removal of system packages...
timeout /t 1 /nobreak > nul
cls
echo Removing Internet Explorer...
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-InternetExplorer-Optional-Package~31bf3856ad364e35~amd64~en-US~11.0.22621.1 > nul
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-InternetExplorer-Optional-Package~31bf3856ad364e35~amd64~~11.0.22621.525 > nul
echo Removing LA57:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-Kernel-LA57-FoD-Package~31bf3856ad364e35~amd64~~10.0.22621.525 > nul
echo Removing Handwriting:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-Handwriting-en-us-Package~31bf3856ad364e35~amd64~~10.0.22621.525 > nul
echo Removing OCR:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-OCR-en-us-Package~31bf3856ad364e35~amd64~~10.0.22621.525 > nul
echo Removing Speech:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-Speech-en-us-Package~31bf3856ad364e35~amd64~~10.0.22621.525 > nul
echo Removing TTS:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-TextToSpeech-en-us-Package~31bf3856ad364e35~amd64~~10.0.22621.525 > nul
echo Removing Media Player Legacy:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~amd64~~10.0.22621.525 > nul
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~wow64~en-US~10.0.22621.1 > nul
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~amd64~~10.0.22621.525 > nul
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~wow64~~10.0.22621.1 > nul
echo Removing Tablet PC Math:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-TabletPCMath-Package~31bf3856ad364e35~amd64~~10.0.22621.525 > nul
echo Removing Wallpapers:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-Wallpaper-Content-Extended-FoD-Package~31bf3856ad364e35~amd64~~10.0.22621.525 > nul
echo Removing Edge:
rd "C:\scratchdir\Program Files (x86)\Microsoft\Edge" /s /q
rd "C:\scratchdir\Program Files (x86)\Microsoft\EdgeUpdate" /s /q
echo Removing OneDrive:
takeown /f C:\scratchdir\Windows\System32\OneDriveSetup.exe
icacls C:\scratchdir\Windows\System32\OneDriveSetup.exe /grant Administrators:F /T /C
del /f /q /s "C:\scratchdir\Windows\System32\OneDriveSetup.exe"
echo Removal complete!
timeout /t 2 /nobreak > nul
cls
echo Loading registry...
reg load HKLM\zCOMPONENTS "c:\scratchdir\Windows\System32\config\COMPONENTS" >nul
reg load HKLM\zDEFAULT "c:\scratchdir\Windows\System32\config\default" >nul
reg load HKLM\zNTUSER "c:\scratchdir\Users\Default\ntuser.dat" >nul
reg load HKLM\zSOFTWARE "c:\scratchdir\Windows\System32\config\SOFTWARE" >nul
reg load HKLM\zSYSTEM "c:\scratchdir\Windows\System32\config\SYSTEM" >nul
echo Bypassing system requirements(on the system image):
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassCPUCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassRAMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassSecureBootCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassStorageCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassTPMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\MoSetup" /v "AllowUpgradesWithUnsupportedTPMOrCPU" /t REG_DWORD /d "1" /f >nul 2>&1
echo Disabling Teams:
Reg add "HKLM\zSOFTWARE\Microsoft\Windows\CurrentVersion\Communications" /v "ConfigureChatAutoInstall" /t REG_DWORD /d "0" /f >nul 2>&1
echo Disabling Sponsored Apps:
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OemPreInstalledAppsEnabled" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zSOFTWARE\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSOFTWARE\Microsoft\PolicyManager\current\device\Start" /v "ConfigureStartPins" /t REG_SZ /d "{\"pinnedList\": [{}]}" /f >nul 2>&1
echo Enabling Local Accounts on OOBE:
Reg add "HKLM\zSOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v "BypassNRO" /t REG_DWORD /d "1" /f >nul 2>&1
copy /y %~dp0autounattend.xml c:\scratchdir\Windows\System32\Sysprep\autounattend.xml
echo Disabling Reserved Storage:
Reg add "HKLM\zSOFTWARE\Microsoft\Windows\CurrentVersion\ReserveManager" /v "ShippedWithReserves" /t REG_DWORD /d "0" /f >nul 2>&1
echo Disabling Chat icon:
Reg add "HKLM\zSOFTWARE\Policies\Microsoft\Windows\Windows Chat" /v "ChatIcon" /t REG_DWORD /d "3" /f >nul 2>&1
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d "0" /f >nul 2>&1
echo Tweaking complete!
echo Unmounting Registry...
reg unload HKLM\zCOMPONENTS >nul 2>&1
reg unload HKLM\zDRIVERS >nul 2>&1
reg unload HKLM\zDEFAULT >nul 2>&1
reg unload HKLM\zNTUSER >nul 2>&1
reg unload HKLM\zSCHEMA >nul 2>&1
reg unload HKLM\zSOFTWARE >nul 2>&1
reg unload HKLM\zSYSTEM >nul 2>&1
echo Cleaning up image...
dism /image:c:\scratchdir /Cleanup-Image /StartComponentCleanup /ResetBase
echo Cleanup complete.
echo Unmounting image...
dism /unmount-image /mountdir:c:\scratchdir /commit
echo Exporting image...
Dism /Export-Image /SourceImageFile:c:\tiny11\sources\install.wim /SourceIndex:%index% /DestinationImageFile:c:\tiny11\sources\install2.wim /compress:max
del c:\tiny11\sources\install.wim
ren c:\tiny11\sources\install2.wim install.wim
echo Windows image completed. Continuing with boot.wim.
timeout /t 2 /nobreak > nul
cls
echo Mounting boot image:
dism /mount-image /imagefile:c:\tiny11\sources\boot.wim /index:2 /mountdir:c:\scratchdir
echo Loading registry...
reg load HKLM\zCOMPONENTS "c:\scratchdir\Windows\System32\config\COMPONENTS" >nul
reg load HKLM\zDEFAULT "c:\scratchdir\Windows\System32\config\default" >nul
reg load HKLM\zNTUSER "c:\scratchdir\Users\Default\ntuser.dat" >nul
reg load HKLM\zSOFTWARE "c:\scratchdir\Windows\System32\config\SOFTWARE" >nul
reg load HKLM\zSYSTEM "c:\scratchdir\Windows\System32\config\SYSTEM" >nul
echo Bypassing system requirements(on the setup image):
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassCPUCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassRAMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassSecureBootCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassStorageCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassTPMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\MoSetup" /v "AllowUpgradesWithUnsupportedTPMOrCPU" /t REG_DWORD /d "1" /f >nul 2>&1
echo Tweaking complete!
echo Unmounting Registry...
reg unload HKLM\zCOMPONENTS >nul 2>&1
reg unload HKLM\zDRIVERS >nul 2>&1
reg unload HKLM\zDEFAULT >nul 2>&1
reg unload HKLM\zNTUSER >nul 2>&1
reg unload HKLM\zSCHEMA >nul 2>&1
reg unload HKLM\zSOFTWARE >nul 2>&1
reg unload HKLM\zSYSTEM >nul 2>&1
echo Unmounting image...
dism /unmount-image /mountdir:c:\scratchdir /commit
cls
echo the tiny11 image is now completed. Proceeding with the making of the ISO...
echo Copying unattended file for bypassing MS account on OOBE...
copy /y %~dp0autounattend.xml c:\tiny11\autounattend.xml
echo.
echo Creating ISO image...
%~dp0oscdimg.exe -m -o -u2 -udfver102 -bootdata:2#p0,e,bc:\tiny11\boot\etfsboot.com#pEF,e,bc:\tiny11\efi\microsoft\boot\efisys.bin c:\tiny11 %~dp0tiny11.iso
echo Creation completed! Press any key to exit the script...
pause
echo Performing Cleanup...
rd c:\tiny11 /s /q
rd c:\scratchdir /s /q
exit

View file

@ -1,233 +0,0 @@
@echo off
setlocal EnableExtensions EnableDelayedExpansion
title tiny11 builder alpha
echo Welcome to the tiny11 image creator!
timeout /t 3 /nobreak > nul
cls
set DriveLetter=
set /p DriveLetter=Please enter the drive letter for the Windows 11 image:
set "DriveLetter=%DriveLetter%:"
echo.
if not exist "%DriveLetter%\sources\boot.wim" (
echo.Can't find Windows OS Installation files in the specified Drive Letter..
echo.
echo.Please enter the correct DVD Drive Letter..
goto :Stop
)
if not exist "%DriveLetter%\sources\install.wim" (
echo.Can't find Windows OS Installation files in the specified Drive Letter..
echo.
echo.Please enter the correct DVD Drive Letter..
goto :Stop
)
md c:\tiny11
echo Copying Windows image...
xcopy.exe /E /I /H /R /Y /J %DriveLetter% c:\tiny11 >nul
echo Copy complete!
sleep 2
cls
echo Getting image information:
dism /Get-WimInfo /wimfile:c:\tiny11\sources\install.wim
set index=
set /p index=Please enter the image index:
set "index=%index%"
echo Mounting Windows image. This may take a while.
echo.
md c:\scratchdir
dism /mount-image /imagefile:c:\tiny11\sources\install.wim /index:%index% /mountdir:c:\scratchdir
echo Mounting complete! Performing removal of applications...
echo Removing Clipchamp...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Clipchamp.Clipchamp_2.5.15.0_neutral_~_yxz26nhyzhsrt
echo Removing News...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.BingNews_4.12.21001.0_neutral_~_8wekyb3d8bbwe
echo Removing Weather...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.BingWeather_4.53.50023.0_neutral_~_8wekyb3d8bbwe
echo Removing Xbox...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.GamingApp_2021.427.138.0_neutral_~_8wekyb3d8bbwe
echo Removing GetHelp...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.GetHelp_10.2206.2011.0_neutral_~_8wekyb3d8bbwe
echo Removing GetStarted...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.Getstarted_2021.2204.1.0_neutral_~_8wekyb3d8bbwe
echo Removing Office Hub...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.MicrosoftOfficeHub_18.2204.1141.0_neutral_~_8wekyb3d8bbwe
echo Removing Solitaire...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.MicrosoftSolitaireCollection_4.12.3171.0_neutral_~_8wekyb3d8bbwe
echo Removing PeopleApp...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.People_2020.901.1724.0_neutral_~_8wekyb3d8bbwe
echo Removing PowerAutomate...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.PowerAutomateDesktop_10.0.3735.0_neutral_~_8wekyb3d8bbwe
echo Removing ToDo...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.Todos_2.54.42772.0_neutral_~_8wekyb3d8bbwe
echo Removing Alarms...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsAlarms_2022.2210.9.0_neutral_~_8wekyb3d8bbwe
echo Removing Mail...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:microsoft.windowscommunicationsapps_16005.14326.20544.0_neutral_~_8wekyb3d8bbwe
echo Removing Feedback Hub...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsFeedbackHub_2022.106.2230.0_neutral_~_8wekyb3d8bbwe
echo Removing Maps...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsMaps_2022.2208.6.0_neutral_~_8wekyb3d8bbwe
echo Removing Sound Recorder...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsSoundRecorder_2021.2208.27.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxTCUI...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.Xbox.TCUI_1.23.28004.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxGamingOverlay...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.XboxGamingOverlay_2.622.3232.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxGameOverlay...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.XboxGameOverlay_1.47.2385.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxSpeechToTextOverlay...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.XboxSpeechToTextOverlay_1.17.29001.0_neutral_~_8wekyb3d8bbwe
echo Removing Your Phone...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.YourPhone_1.22022.147.0_neutral_~_8wekyb3d8bbwe
echo Removing Music...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.ZuneMusic_11.2210.33.0_neutral_~_8wekyb3d8bbwe
echo Removing Video...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.ZuneVideo_2019.22120.10031.0_neutral_~_8wekyb3d8bbwe
echo Removing Family...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:MicrosoftCorporationII.MicrosoftFamily_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing QuickAssist...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:MicrosoftCorporationII.QuickAssist_2022.825.2016.0_neutral_~_8wekyb3d8bbwe
echo Removing Teams...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:MicrosoftTeams_23002.403.1788.1930_x64__8wekyb3d8bbwe
echo Removing Cortana...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.549981C3F5F10_4.2204.13303.0_neutral_~_8wekyb3d8bbwe
echo Removing of system apps complete! Now proceeding to removal of system packages...
timeout /t 1 /nobreak > nul
cls
echo Removing Internet Explorer...
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-InternetExplorer-Optional-Package~31bf3856ad364e35~amd64~en-US~11.0.25300.1000 > nul
echo Removing LA57:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-Kernel-LA57-FoD-Package~31bf3856ad364e35~amd64~~10.0.25300.1000 > nul
echo Removing Handwriting:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-Handwriting-en-us-Package~31bf3856ad364e35~amd64~~10.0.25300.1000 > nul
echo Removing OCR:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-OCR-en-us-Package~31bf3856ad364e35~amd64~~10.0.25300.1000 > nul
echo Removing Speech:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-Speech-en-us-Package~31bf3856ad364e35~amd64~~10.0.25300.1000 > nul
echo Removing TTS:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-TextToSpeech-en-us-Package~31bf3856ad364e35~amd64~~10.0.25300.1000 > nul
echo Removing Media Player Legacy:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~amd64~~10.0.25300.1000 > nul
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~wow64~en-US~10.0.25300.1000 > nul
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~amd64~~10.0.25300.1000 > nul
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~wow64~~10.0.25300.1000 > nul
echo Removing Tablet PC Math:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-TabletPCMath-Package~31bf3856ad364e35~amd64~~10.0.25300.1000 > nul
echo Removing Wallpapers:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-Wallpaper-Content-Extended-FoD-Package~31bf3856ad364e35~amd64~~10.0.25300.1000 > nul
echo Removing Edge:
rd "C:\scratchdir\Program Files (x86)\Microsoft\Edge" /s /q
rd "C:\scratchdir\Program Files (x86)\Microsoft\EdgeUpdate" /s /q
echo Removing OneDrive:
takeown /f C:\scratchdir\Windows\System32\OneDriveSetup.exe
icacls C:\scratchdir\Windows\System32\OneDriveSetup.exe /grant Administrators:F /T /C
del /f /q /s "C:\scratchdir\Windows\System32\OneDriveSetup.exe"
echo Removal complete!
timeout /t 2 /nobreak > nul
cls
echo Loading registry...
reg load HKLM\zCOMPONENTS "c:\scratchdir\Windows\System32\config\COMPONENTS" >nul
reg load HKLM\zDEFAULT "c:\scratchdir\Windows\System32\config\default" >nul
reg load HKLM\zNTUSER "c:\scratchdir\Users\Default\ntuser.dat" >nul
reg load HKLM\zSOFTWARE "c:\scratchdir\Windows\System32\config\SOFTWARE" >nul
reg load HKLM\zSYSTEM "c:\scratchdir\Windows\System32\config\SYSTEM" >nul
echo Bypassing system requirements(on the system image):
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassCPUCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassRAMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassSecureBootCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassStorageCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassTPMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\MoSetup" /v "AllowUpgradesWithUnsupportedTPMOrCPU" /t REG_DWORD /d "1" /f >nul 2>&1
echo Disabling Teams:
Reg add "HKLM\zSOFTWARE\Microsoft\Windows\CurrentVersion\Communications" /v "ConfigureChatAutoInstall" /t REG_DWORD /d "0" /f >nul 2>&1
echo Disabling Sponsored Apps:
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OemPreInstalledAppsEnabled" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zSOFTWARE\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSOFTWARE\Microsoft\PolicyManager\current\device\Start" /v "ConfigureStartPins" /t REG_SZ /d "{\"pinnedList\": [{}]}" /f >nul 2>&1
echo Enabling Local Accounts on OOBE:
Reg add "HKLM\zSOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v "BypassNRO" /t REG_DWORD /d "1" /f >nul 2>&1
copy /y %~dp0autounattend.xml c:\scratchdir\Windows\System32\Sysprep\autounattend.xml
echo Disabling Reserved Storage:
Reg add "HKLM\zSOFTWARE\Microsoft\Windows\CurrentVersion\ReserveManager" /v "ShippedWithReserves" /t REG_DWORD /d "0" /f >nul 2>&1
echo Disabling Chat icon:
Reg add "HKLM\zSOFTWARE\Policies\Microsoft\Windows\Windows Chat" /v "ChatIcon" /t REG_DWORD /d "3" /f >nul 2>&1
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d "0" /f >nul 2>&1
echo Tweaking complete!
echo Unmounting Registry...
reg unload HKLM\zCOMPONENTS >nul 2>&1
reg unload HKLM\zDRIVERS >nul 2>&1
reg unload HKLM\zDEFAULT >nul 2>&1
reg unload HKLM\zNTUSER >nul 2>&1
reg unload HKLM\zSCHEMA >nul 2>&1
reg unload HKLM\zSOFTWARE >nul 2>&1
reg unload HKLM\zSYSTEM >nul 2>&1
echo Cleaning up image...
dism /image:c:\scratchdir /Cleanup-Image /StartComponentCleanup /ResetBase
echo Cleanup complete.
echo Unmounting image...
dism /unmount-image /mountdir:c:\scratchdir /commit
echo Exporting image...
Dism /Export-Image /SourceImageFile:c:\tiny11\sources\install.wim /SourceIndex:%index% /DestinationImageFile:c:\tiny11\sources\install2.wim /compress:max
del c:\tiny11\sources\install.wim
ren c:\tiny11\sources\install2.wim install.wim
echo Windows image completed. Continuing with boot.wim.
timeout /t 2 /nobreak > nul
cls
echo Mounting boot image:
dism /mount-image /imagefile:c:\tiny11\sources\boot.wim /index:2 /mountdir:c:\scratchdir
echo Loading registry...
reg load HKLM\zCOMPONENTS "c:\scratchdir\Windows\System32\config\COMPONENTS" >nul
reg load HKLM\zDEFAULT "c:\scratchdir\Windows\System32\config\default" >nul
reg load HKLM\zNTUSER "c:\scratchdir\Users\Default\ntuser.dat" >nul
reg load HKLM\zSOFTWARE "c:\scratchdir\Windows\System32\config\SOFTWARE" >nul
reg load HKLM\zSYSTEM "c:\scratchdir\Windows\System32\config\SYSTEM" >nul
echo Bypassing system requirements(on the setup image):
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassCPUCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassRAMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassSecureBootCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassStorageCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassTPMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\MoSetup" /v "AllowUpgradesWithUnsupportedTPMOrCPU" /t REG_DWORD /d "1" /f >nul 2>&1
echo Tweaking complete!
echo Unmounting Registry...
reg unload HKLM\zCOMPONENTS >nul 2>&1
reg unload HKLM\zDRIVERS >nul 2>&1
reg unload HKLM\zDEFAULT >nul 2>&1
reg unload HKLM\zNTUSER >nul 2>&1
reg unload HKLM\zSCHEMA >nul 2>&1
reg unload HKLM\zSOFTWARE >nul 2>&1
reg unload HKLM\zSYSTEM >nul 2>&1
echo Unmounting image...
dism /unmount-image /mountdir:c:\scratchdir /commit
cls
echo the tiny11 image is now completed. Proceeding with the making of the ISO...
echo Copying unattended file for bypassing MS account on OOBE...
copy /y %~dp0autounattend.xml c:\tiny11\autounattend.xml
echo.
echo Creating ISO image...
%~dp0oscdimg.exe -m -o -u2 -udfver102 -bootdata:2#p0,e,bc:\tiny11\boot\etfsboot.com#pEF,e,bc:\tiny11\efi\microsoft\boot\efisys.bin c:\tiny11 %~dp0tiny11.iso
echo Creation completed! Press any key to exit the script...
pause
echo Performing Cleanup...
rd c:\tiny11 /s /q
rd c:\scratchdir /s /q
exit

View file

@ -1,234 +0,0 @@
@echo off
setlocal EnableExtensions EnableDelayedExpansion
title tiny11 builder alpha
echo Welcome to the tiny11 image creator!
timeout /t 3 /nobreak > nul
cls
set DriveLetter=
set /p DriveLetter=Please enter the drive letter for the Windows 11 image:
set "DriveLetter=%DriveLetter%:"
echo.
if not exist "%DriveLetter%\sources\boot.wim" (
echo.Can't find Windows OS Installation files in the specified Drive Letter..
echo.
echo.Please enter the correct DVD Drive Letter..
goto :Stop
)
if not exist "%DriveLetter%\sources\install.wim" (
echo.Can't find Windows OS Installation files in the specified Drive Letter..
echo.
echo.Please enter the correct DVD Drive Letter..
goto :Stop
)
md c:\tiny11
echo Copying Windows image...
xcopy.exe /E /I /H /R /Y /J %DriveLetter% c:\tiny11 >nul
echo Copy complete!
sleep 2
cls
echo Getting image information:
dism /Get-WimInfo /wimfile:c:\tiny11\sources\install.wim
set index=
set /p index=Please enter the image index:
set "index=%index%"
echo Mounting Windows image. This may take a while.
echo.
md c:\scratchdir
dism /mount-image /imagefile:c:\tiny11\sources\install.wim /index:%index% /mountdir:c:\scratchdir
echo Mounting complete! Performing removal of applications...
echo Removing Clipchamp...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Clipchamp.Clipchamp_2.2.8.0_neutral_~_yxz26nhyzhsrt
echo Removing News...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.BingNews_2022.507.446.0_neutral_~_8wekyb3d8bbwe
echo Removing Weather...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.BingWeather_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing Xbox...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.GamingApp_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing GetHelp...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.GetHelp_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing GetStarted...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.Getstarted_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing Office Hub...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.MicrosoftOfficeHub_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing Solitaire...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.MicrosoftSolitaireCollection_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing PeopleApp...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.People_2022.507.446.0_neutral_~_8wekyb3d8bbwe
echo Removing PowerAutomate...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.PowerAutomateDesktop_2022.507.446.0_neutral_~_8wekyb3d8bbwe
echo Removing ToDo...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.Todos_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing Alarms...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsAlarms_2022.507.446.0_neutral_~_8wekyb3d8bbwe
echo Removing Mail...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:microsoft.windowscommunicationsapps_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing Feedback Hub...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsFeedbackHub_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing Maps...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsMaps_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing Sound Recorder...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.WindowsSoundRecorder_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxTCUI...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.Xbox.TCUI_2022.507.446.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxGamingOverlay...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.XboxGamingOverlay_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxGameOverlay...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.XboxGameOverlay_2022.507.446.0_neutral_~_8wekyb3d8bbwe
echo Removing XboxSpeechToTextOverlay...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.XboxSpeechToTextOverlay_2022.507.446.0_neutral_~_8wekyb3d8bbwe
echo Removing Your Phone...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.YourPhone_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing Music...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.ZuneMusic_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing Video...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.ZuneVideo_2022.507.446.0_neutral_~_8wekyb3d8bbwe
echo Removing Family...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:MicrosoftCorporationII.MicrosoftFamily_2022.507.447.0_neutral_~_8wekyb3d8bbwe
echo Removing QuickAssist...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:MicrosoftCorporationII.QuickAssist_2022.507.446.0_neutral_~_8wekyb3d8bbwe
echo Removing Teams...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:MicrosoftTeams_23002.403.1788.1930_x64__8wekyb3d8bbwe
echo Removing Cortana...
dism /image:c:\scratchdir /Remove-ProvisionedAppxPackage /PackageName:Microsoft.549981C3F5F10_4.2204.13303.0_neutral_~_8wekyb3d8bbwe
echo Removing of system apps complete! Now proceeding to removal of system packages...
timeout /t 1 /nobreak > nul
cls
echo Removing Internet Explorer...
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-InternetExplorer-Optional-Package~31bf3856ad364e35~amd64~en-US~11.0.22621.1 > nul
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-InternetExplorer-Optional-Package~31bf3856ad364e35~amd64~~11.0.22621.1265 > nul
echo Removing LA57:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-Kernel-LA57-FoD-Package~31bf3856ad364e35~amd64~~10.0.22621.1265 > nul
echo Removing Handwriting:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-Handwriting-en-us-Package~31bf3856ad364e35~amd64~~10.0.22621.1265 > nul
echo Removing OCR:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-OCR-en-us-Package~31bf3856ad364e35~amd64~~10.0.22621.1265 > nul
echo Removing Speech:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-Speech-en-us-Package~31bf3856ad364e35~amd64~~10.0.22621.1265 > nul
echo Removing TTS:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-LanguageFeatures-TextToSpeech-en-us-Package~31bf3856ad364e35~amd64~~10.0.22621.1265 > nul
echo Removing Media Player Legacy:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~amd64~~10.0.22621.1265 > nul
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~wow64~en-US~10.0.22621.1 > nul
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~amd64~~10.0.22621.1265 > nul
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-MediaPlayer-Package~31bf3856ad364e35~wow64~~10.0.22621.1 > nul
echo Removing Tablet PC Math:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-TabletPCMath-Package~31bf3856ad364e35~amd64~~10.0.22621.1265 > nul
echo Removing Wallpapers:
dism /image:c:\scratchdir /Remove-Package /PackageName:Microsoft-Windows-Wallpaper-Content-Extended-FoD-Package~31bf3856ad364e35~amd64~~10.0.22621.1265 > nul
echo Removing Edge:
rd "C:\scratchdir\Program Files (x86)\Microsoft\Edge" /s /q
rd "C:\scratchdir\Program Files (x86)\Microsoft\EdgeUpdate" /s /q
echo Removing OneDrive:
takeown /f C:\scratchdir\Windows\System32\OneDriveSetup.exe
icacls C:\scratchdir\Windows\System32\OneDriveSetup.exe /grant Administrators:F /T /C
del /f /q /s "C:\scratchdir\Windows\System32\OneDriveSetup.exe"
echo Removal complete!
timeout /t 2 /nobreak > nul
cls
echo Loading registry...
reg load HKLM\zCOMPONENTS "c:\scratchdir\Windows\System32\config\COMPONENTS" >nul
reg load HKLM\zDEFAULT "c:\scratchdir\Windows\System32\config\default" >nul
reg load HKLM\zNTUSER "c:\scratchdir\Users\Default\ntuser.dat" >nul
reg load HKLM\zSOFTWARE "c:\scratchdir\Windows\System32\config\SOFTWARE" >nul
reg load HKLM\zSYSTEM "c:\scratchdir\Windows\System32\config\SYSTEM" >nul
echo Bypassing system requirements(on the system image):
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassCPUCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassRAMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassSecureBootCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassStorageCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassTPMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\MoSetup" /v "AllowUpgradesWithUnsupportedTPMOrCPU" /t REG_DWORD /d "1" /f >nul 2>&1
echo Disabling Teams:
Reg add "HKLM\zSOFTWARE\Microsoft\Windows\CurrentVersion\Communications" /v "ConfigureChatAutoInstall" /t REG_DWORD /d "0" /f >nul 2>&1
echo Disabling Sponsored Apps:
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "OemPreInstalledAppsEnabled" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "PreInstalledAppsEnabled" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\ContentDeliveryManager" /v "SilentInstalledAppsEnabled" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zSOFTWARE\Policies\Microsoft\Windows\CloudContent" /v "DisableWindowsConsumerFeatures" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSOFTWARE\Microsoft\PolicyManager\current\device\Start" /v "ConfigureStartPins" /t REG_SZ /d "{\"pinnedList\": [{}]}" /f >nul 2>&1
echo Enabling Local Accounts on OOBE:
Reg add "HKLM\zSOFTWARE\Microsoft\Windows\CurrentVersion\OOBE" /v "BypassNRO" /t REG_DWORD /d "1" /f >nul 2>&1
copy /y %~dp0autounattend.xml c:\scratchdir\Windows\System32\Sysprep\autounattend.xml
echo Disabling Reserved Storage:
Reg add "HKLM\zSOFTWARE\Microsoft\Windows\CurrentVersion\ReserveManager" /v "ShippedWithReserves" /t REG_DWORD /d "0" /f >nul 2>&1
echo Disabling Chat icon:
Reg add "HKLM\zSOFTWARE\Policies\Microsoft\Windows\Windows Chat" /v "ChatIcon" /t REG_DWORD /d "3" /f >nul 2>&1
Reg add "HKLM\zNTUSER\SOFTWARE\Microsoft\Windows\CurrentVersion\Explorer\Advanced" /v "TaskbarMn" /t REG_DWORD /d "0" /f >nul 2>&1
echo Tweaking complete!
echo Unmounting Registry...
reg unload HKLM\zCOMPONENTS >nul 2>&1
reg unload HKLM\zDRIVERS >nul 2>&1
reg unload HKLM\zDEFAULT >nul 2>&1
reg unload HKLM\zNTUSER >nul 2>&1
reg unload HKLM\zSCHEMA >nul 2>&1
reg unload HKLM\zSOFTWARE >nul 2>&1
reg unload HKLM\zSYSTEM >nul 2>&1
echo Cleaning up image...
dism /image:c:\scratchdir /Cleanup-Image /StartComponentCleanup /ResetBase
echo Cleanup complete.
echo Unmounting image...
dism /unmount-image /mountdir:c:\scratchdir /commit
echo Exporting image...
Dism /Export-Image /SourceImageFile:c:\tiny11\sources\install.wim /SourceIndex:%index% /DestinationImageFile:c:\tiny11\sources\install2.wim /compress:max
del c:\tiny11\sources\install.wim
ren c:\tiny11\sources\install2.wim install.wim
echo Windows image completed. Continuing with boot.wim.
timeout /t 2 /nobreak > nul
cls
echo Mounting boot image:
dism /mount-image /imagefile:c:\tiny11\sources\boot.wim /index:2 /mountdir:c:\scratchdir
echo Loading registry...
reg load HKLM\zCOMPONENTS "c:\scratchdir\Windows\System32\config\COMPONENTS" >nul
reg load HKLM\zDEFAULT "c:\scratchdir\Windows\System32\config\default" >nul
reg load HKLM\zNTUSER "c:\scratchdir\Users\Default\ntuser.dat" >nul
reg load HKLM\zSOFTWARE "c:\scratchdir\Windows\System32\config\SOFTWARE" >nul
reg load HKLM\zSYSTEM "c:\scratchdir\Windows\System32\config\SYSTEM" >nul
echo Bypassing system requirements(on the setup image):
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zDEFAULT\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV1" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zNTUSER\Control Panel\UnsupportedHardwareNotificationCache" /v "SV2" /t REG_DWORD /d "0" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassCPUCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassRAMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassSecureBootCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassStorageCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\LabConfig" /v "BypassTPMCheck" /t REG_DWORD /d "1" /f >nul 2>&1
Reg add "HKLM\zSYSTEM\Setup\MoSetup" /v "AllowUpgradesWithUnsupportedTPMOrCPU" /t REG_DWORD /d "1" /f >nul 2>&1
echo Tweaking complete!
echo Unmounting Registry...
reg unload HKLM\zCOMPONENTS >nul 2>&1
reg unload HKLM\zDRIVERS >nul 2>&1
reg unload HKLM\zDEFAULT >nul 2>&1
reg unload HKLM\zNTUSER >nul 2>&1
reg unload HKLM\zSCHEMA >nul 2>&1
reg unload HKLM\zSOFTWARE >nul 2>&1
reg unload HKLM\zSYSTEM >nul 2>&1
echo Unmounting image...
dism /unmount-image /mountdir:c:\scratchdir /commit
cls
echo the tiny11 image is now completed. Proceeding with the making of the ISO...
echo Copying unattended file for bypassing MS account on OOBE...
copy /y %~dp0autounattend.xml c:\tiny11\autounattend.xml
echo.
echo Creating ISO image...
%~dp0oscdimg.exe -m -o -u2 -udfver102 -bootdata:2#p0,e,bc:\tiny11\boot\etfsboot.com#pEF,e,bc:\tiny11\efi\microsoft\boot\efisys.bin c:\tiny11 %~dp0tiny11.iso
echo Creation completed! Press any key to exit the script...
pause
echo Performing Cleanup...
rd c:\tiny11 /s /q
rd c:\scratchdir /s /q
exit