Created
March 5, 2023 02:56
-
-
Save rzrabbi/bfcf5c28419772b64723619c6228125f to your computer and use it in GitHub Desktop.
Save this script as a .bat file and run it
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@echo off | |
echo Deleting temporary files... | |
del /q /s %TEMP%\*.* | |
echo Temporary files deleted. | |
echo Deleting prefetch files... | |
del /q /s %SystemRoot%\Prefetch\*.* | |
echo Prefetch files deleted. | |
echo Clearing DNS cache... | |
ipconfig /flushdns | |
echo DNS cache cleared. | |
echo Clearing Windows event logs... | |
wevtutil.exe cl Application | |
wevtutil.exe cl System | |
echo Event logs cleared. | |
echo Clearing browser cache and history... | |
rundll32.exe InetCpl.cpl,ClearMyTracksByProcess 255 | |
echo Browser cache and history cleared. | |
echo Cleaning up disk... | |
cleanmgr.exe /sagerun:1 | |
echo Disk cleanup completed. | |
echo Done. | |
pause |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment