Clear Temp Directory on Startup with Disk Cleanup

Recently, we saw how to clean up the temp directory automatically in Windows 10 using a simple batch file. In this article, we will see how to perform the same task using the built-in Disk Cleanup tool (cleanmgr.exe). Unlike the batch file, it shows a progress window with messages and a progress bar which gives you an idea of how long the operation will take.