The parameters of the del command
/F Forces a read-only file to be deleted.
/s Deletes the specified file from all subdirectories.
/q Quiet mode. Confirmation is not required when global wildcard characters are deleted.
Parameters for Rd Command
/s In addition to the directory itself, all subdirectories and files under the specified directory are also deleted. Used to delete a directory tree.
/q Quiet mode
/s does not require confirmation when deleting a tree.
Code A
@echo off & Title cleaning system garbage
del/f/s/q%systemdrive%\*.tmp
del/f/s/q%systemdrive%\*.mp3 del/f/s/q
%s Ystemdrive%\recycled\*.*
del/f/s/q%windir%\*.bak
del/f/s/q%windir%\prefetch\*.* rd/s/
q%windir%\tem P & MD%windir%\temp
del/f/q%userprofile%\cookies\*.*
del/f/s/q "C:\Documents and Settings\administrato R\local settings\history "
del/f/s/q" C:\Documents and Settings\Administrator\Local settings\temporary Internet Files "
del/f/s/q" C:\Documents and Settings\Administrator\Local settings\temp "
del/f/s/q" C:\Documents and Settings\Administrator\Local Settings\temp\_xl7vss_ "
Code two
@echo off
Echo is cleaning up the system garbage file, please wait ...
del/f/s/q%systemdrive%\*.tmp del/f/s/q%systemdrive%\*._mp del/f/s/q%systemdrive%\*.log del/f
/s
/ Q%systemdrive%\*.gid
del/f/s/q%systemdrive%\*.chk
del/f/s/q%systemdrive%\*.old del/f/s/q%SYSTEMDR
Ive%\recycled\*.*
del/f/s/q%windir%\*.bak
del/f/s/q%windir%\prefetch\*.* rd/s/
q%windir%\temp ; MD%windir%\temp
del/f/q%userprofile%\cookies\*.*
del/f/q%userprofile%\recent\*.* del/f/s/q
"%use Rprofile%\local settings\temporary Internet files\*.* "
del/f/s/q"
%userprofile%\local settings\temp\*.* " del/f/s/q "%userprofile%\recent\*.*"
Then save the above to clean up the garbage batch. bat, of course, everyone can add or subtract according to their own needs directory or file type.