|
本帖最后由 kkkssc 于 2019-11-9 12:07 编辑
set date=%date%
set /a namedate=%date:~0,4%
set /a date_month=%date:~5,2%
set /a date_day=%date:~8,2%
if %date_month% leq 9 set namedate=%namedate%0%date_month% else set namedate=%namedate%%date_month%
if %date_day% leq 9 set namedate=%namedate%0%date_day% else set namedate=%namedate%%date_day%
set time=%time%
set /a nametime=%time:~0,2%
set /a time_minute=%time:~3,2%
set /a time_second=%time:~6,2%
if %nametime% leq 9 set nametime=0%nametime%
if %time_minute% leq 9 set nametime=%nametime%0%time_minute% else set nametime=%nametime%%time_minute%
if %time_second% leq 9 set nametime=%nametime%0%time_second% else set nametime=%nametime%%time_second%
rename F:\Temp\FireFoxCookiesBackup\cookies.sqlite "cookies_%namedate%%nametime%.sqlite"
cd "X:\Mozilla Firefox\UserProfileKH"
xcopy cookies.sqlite F:\Temp\FireFoxCookiesBackup\ /y
@ping 127.0.0.1 -n 5 >null
@exit
一个备份ramdisk中firefox cookies的小脚本,平时没问题,但是只要当有数字出现在9~15的时候,就会报进制错误,不能执行,大侠们看看怎么改? |
|