Batch Processing of Kira freedom write

Source: Internet
Author: User

Small version of process management batch processing (almost the first) Copy codeThe Code is as follows: @ echo off
Title Process Management
Color 3F
Echo Process Management batch processing small version
Echo.
Echo lxsea Kira freedom
Echo is applicable to simple operations that cannot be opened by the task manager and virus detection at the same time.
Echo www.lxsea.com
Tasklist
Pause
Color B1
Echo save data (.csv file will be generated in this directory)
Echo.
Echo
Echo.
Echo updates the process file every time it is used.
Echo.
When echo is used for the second time, it will change tasklist1 to tasklist0. The next operation will delete tasklist0, which repeats in a loop.
Pause
If exist tasklist0.csv del/q tasklist0.csv
If exist tasklist1.csv ren tasklist1.csv tasklist0.csv
Tasklist/fo: csv> tasklist1.csv
If exist tasklist0.csv fc tasklist1.csv tasklist0.csv
Echo stops the process by PID.
The echo process ID can be viewed in the preceding table.
It is dangerous to stop echo. Please select it with caution.
Close echo directly if you do not want.
Color FC
Set Output =
Set/p Enter = Enter PID:
NTSD-c q-P % Enter %
Echo welcome to the ideal technical forum www.lxsea.com
Pause
: End

This is used to compare the batch processing of files (it seems naive now ):Copy codeThe Code is as follows: @ echo off
Color FC
Title check dll files and exe files under C: \ WINDOWS \ system32
Echo .-------------------------------------------------------------------------------
Echo. Check
Dll and exe files under echo. C: \ WINDOWS \ system32
Echo. made by kira freedom
Echo. wwww.lxsea.com welcome
Echo .-------------------------------------------------------------------------------
Echo. At the first operation, 0.txt will be used to record the exe and dll files.
Echo. For the second time, 1.txt will be merged and automatically compared with 0.txt.
Echo. used to determine whether a new file is generated
Echo. This is because system32 loves hiding points for viruses.
If not exist 0.txt goto begin
Rem upload has 0.txt
If exist 1.txt del 1.txt
Delete if rem queue has 1.txt or
Ren 0.txt 1.txt
Rem changes 0.txtto 1.txt
: Begin
Dir/B/A: C: \ WINDOWS \ system32 \ *. exe> 0.txt & dir/B/A: C: \ WINDOWS \ system32 \ *. dll> 0.txt
Rem or above/A: displays the meaning of all files
Echo.
Echo.
Echo ┌ ── ─
Set/p = ■ <nul
For/L % I in (1 1 20) do set/p a = ■ <nul & ping/n 1 127.0.0.1> nul
Echo 100% %
Echo └ ── ─
If errorlevel 1 echo fails, maybe your system is not attached to disk C.
If errorlevel 0 echo is created successfully
If not exist 1.txt goto end
Set/p s = press enter to compare files
Cls
Color 8F
Echo. If there is a difference, it will appear (for example ):
Echo. ***** 0.txt-----------file 0.txt
Echo. ***** 1.txt-----------file 1.txt
Echo. 123.dll-----------file 0.txtdifferent from 1.txt
Echo. 12.exe------------different from 1.txt in file 0.txt
Echo. ***** --------------- except for 1.txtand 0.txt
Echo. The difference between 0.txtand 1.txt is that 123.dlland 12.exe are added to 0.txt!
Set/p j = press enter to start
Fc 0.txt 1.txt
: End
Set/p = press enter to exit

Searching for files (this is just fun... in fact, it's not so annoying to use p to find files)Copy codeThe code is as follows: code by freedom @ www.lxsea.com
: Made in 2009_7_2
@ Echo off
Setlocal EnableDelayedExpansion
Goto new
: Start
Set o =
Set j =
Set wen =
Set/p cc =
: New
Echo.
Echo helps you find files
Echo.
Echo 1. view the file list (view only the current directory)
Echo.
Echo 2. open the file (both the current directory and internal directory)
Set/p j = enter the letter number (Press enter to exit ):
If % j % equ 1 goto: fin
If % j % neq 2 echo No. Error & cls & goto: start
: Wen
For/f "delims =" % a in ('dir/B/s') do echo % a> 1.txt
Set/p wen = What is the file you are looking?
For/f "eol =-" % I in ('Find "% wen %" 1.txt ') do echo file location: % I & start % I
Set/p o = whether to continue searching for files (Y/N ):
If/I % o % = "Y" goto: wen
Del 1.txt/q
Cls
Goto start
: Fin
Cls
Dir/:
Set/p o = whether to search for a file (Y/N ):
If/I % o % = Y goto: wen else goto: fin
Cls
If/I % o % = N goto: start
Pause

This is recently written to prohibit program running. The IFEO method of ws2_32.dll is too lazy to write ..........Copy codeThe Code is as follows: madeby quira freedom batch processing house 20090812
@ Echo off & setlocal ENABLEDELAYEDEXPANSION
Title uses WS2_32.dll to prevent files from running the batch processing house
Echo.
Echo uses ws2_32.dll to prevent program running
Echo.
The echo program is not perfect. It's just tired of IFEO.
Echo.
Echo is invalid for a green program or does not call this dll
Echo.
: New
Echo 1. Disable programs
Echo 2. view the disabled list
Echo 3. Delete disabled programs
Set cho =
Set/p cho = input 1 ~ 3:
If % cho % equ 1 goto mdd
If % cho % equ 2 goto viewd
If % cho % equ 3 goto deld
Echo.
Goto new
: Qs
I am still playing with echo ~ Change address
: Mdd
Set place =
: Check
Set/p place = directory address of the input file (for example, D: \ exe ):
If exist c: \ bad find "% place %" c: \ bad.txt> nul & goto qs
If not exist "% place %" goto check
Md "% place %" \ ws2_32.dll \ fr ..\
Echo % place %> c: \ bad.txt
Echo has been created ~~~~~~
Pause> nul
Cls
Goto new
: Bads
Echo does not have this program. Look at the table.
Pause> nul
: Viewd
If not exist "c: \ bad.txt" goto wro
Type c: \ bad.txt
Pause> nul
Cls
Goto new
: Wro
Echo, you have not run this program or the document has been lost. Sorry ~~
Pause> nul
Cls
Goto new
: Deld
Set kill =
Set/p kill = enter the path of the program to be deleted:
Find "% kill %" c: \ bad.txt> nul | goto bads
Rd "% kill % \ ws2_32.dll"/s/q
Echo.> tem.txt
@ For/f "tokens = * delims =" % I in ('findstr/I/v/c: % kill % c: \ bad.txt ') do (
Set var = % I
Echo! Var!> Tem.txt
)
Copy tem.txt c: \ bad.txt> nul
Echo complete
Pause> nul
Cls
Goto new

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.