Simple little tip here to delete all files in a directory that contain a given string using findstr, for and del. for /f "delims=" %f in ('findstr /m "yourstring" *.*') do @del /f /q %~fRead More Command to Delete Files That Contain a String in MS-DOS
Came across a nice tip when I was researching an unrelated problem today. I discovered that I could use dism to cleanup Vista/7/2008 Service Pack install backup files to reclaim space! This comes with a big fat warning… [stextbox id=”warning”]Warning! The service pack can’t be uninstalled after this operation is completed. This operation will remove…Read More Cleanup Service Pack Backup Files to Reclaim Space
I’ve had this around for the longest time and figured I better put it here before I lose it forever to the dying Microsoft releases. Note: This also cleans up VMware temporary files which build up over time. See this post for more information: VMware Tray Dump Files Chewing up Space Update: Added line to…Read More Batch File to Cleanup Windows 2000, XP and Server 2003 User Profiles, Temp Folders, Internet Explorer Temporary Files
Batch rename files using Windows command line. for /d /r %x in (“*”) do pushd “%x” && ren *.eml *.msg && popd Recently restored about 18k emails in various folders from a PST file which exports as an .MSG formatted file. I then reconverted those .MSG to .EML format. Now, the mail server I’m using…Read More Batch Rename Files and/or Folders in Windows Command Line
Wow, I’m ignorant. I discovered that I have been missing out on a great trick I learned the other night when trying to manually rename hundreds of photos. A Google search showed me the errors of my ways… You can easily batch rename files in Windows explorer. In this example, there are a handful of…Read More Batch Rename Images and Other Files in Windows – Easily!
This script simply cleans up all users’ temporary files and temporary internet files. This works on Windows XP, Windows Server 2003. @echo off setlocal @for /d %%d in ( “C:Documents and Settings*” ) do @( echo %%d if exist “%%dLocal Settings” ( if exist “%%dLocal SettingsTemp” ( for /d %%e in ( “%%dLocal SettingsTemp*” )…Read More Cleanup All Users' Temporary Files