Skip to content

Instantly share code, notes, and snippets.

#!/usr/bin/env bash -ex
set -euo pipefail
shopt -s inherit_errexit nullglob
YW=$(echo "\033[33m")
BL=$(echo "\033[36m")
RD=$(echo "\033[01;31m")
BGN=$(echo "\033[4;92m")
GN=$(echo "\033[1;92m")
DGN=$(echo "\033[32m")
CL=$(echo "\033[m")
@p3x-robot
p3x-robot / windows10-reduce-winsxs-folder-plus-delete-temporary-files.cmd
Last active October 3, 2022 15:22
🗑️ Windows 10 - reduce WinSxS folder and delete temporary files
REM you need to execute in adminstrator command prompt
REM based on
REM https://docs.microsoft.com/en-us/windows-hardware/manufacture/desktop/clean-up-the-winsxs-folder
Dism.exe /online /Cleanup-Image /StartComponentCleanup
REM All existing service packs and updates cannot be uninstalled after this command is completed.
REM This will not block the uninstallation of future service packs or updates
Dism.exe /online /Cleanup-Image /SPSuperseded
Dism.exe /online /Cleanup-Image /StartComponentCleanup /ResetBase