VC project spam gadgets (. BAT)

Source: Internet
Author: User
Tags exit in

In the C ++ project directory written with vs, there are always some unwanted temporary compilation files or vs data index files. These files are large in size, for example. the number of SDF files reaches about 70 MB, which makes code backup troublesome.

When backing up code, you only need to leave some required source files, which are usually less than 1 MB in total. Therefore, clearing the project directory is very necessary.

The following is a. Bat tool for clearing the project directory:

@ Echo off
Echo ===================================================== =====
Echo = [name:] project cleanup. Bat =
Echo = [] cbnote =
Echo = [Date:] 2014-08-28 =
Echo = [version:] ver1.0 =

Echo = [URL:] http://blog.csdn.net/cbnotes =
Echo ===================================================== =====
Pause
ECHO is being cleared. Please wait ......
Echo ===================================================== ==========================================

For/R % dir % d in (vc60.pdb vc90.pdb *. exp *. OBJ *. PCH *. IDB *. NCB *. opt *. PLG *. res *. SBR *. ILK *. APS *. SDF *. temp *. DCU *. BSc) Do del/f/S/Q "% d" 2> NUL

For/R. % d in (.) do RD/S/Q "% d \ debug" 2> NUL

For/R. % d in (.) do RD/S/Q "% d \ release" 2> NUL
Echo ===================================================== ==========================================

ECHO file cleared! This program will exit in 5 seconds! Now the countdown .........
@ Echo off
Echo wscript. Sleep 300> % Temp %. \ TMP $. vbs
Set/A I = 5
: Timeout
If % I % = 0 goto next
Setlocal
Set/A I = % I %-1
Echo countdown ...... % I %
Cscript // nologo % Temp %. \ TMP $. vbs
Goto timeout
Goto end
: Next
CLS &
Echo.

Copy the above Code to notepad and change the name to XXX. bat!

The files to be cleared are incomplete. You can add them as needed.

[Note:] The tool is searched and deleted in the directory where it is located.

VC project spam gadgets (. BAT)

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.