win10 保存锁屏壁纸

Posted on Posted in bat

bat 脚本,放到桌面

XnView -- download

@ECHO OFF
color 2e
title=拷贝win10壁纸
echo ****************************************  
echo copy win10 壁纸  
echo "https://www.xnview.com/en/nconvert/#downloads" 下载后解压放到桌面
echo **************************************** 

set desktop=C:\Users\%username%\Desktop
set tmpdir=tmppapper
set win10papperdir=C:\Users\%username%\AppData\Local\Packages\Microsoft.Windows.ContentDeliveryManager_cw5n1h2txyewy\LocalState\Assets
:: xnview 路径
set xnview=%desktop%\XnView

if exist %desktop%\%tmpdir% (
    rd /s /q %desktop%\%tmpdir%
)
ping -n 1 127.0.0.1 > nul
::timeout /t 3 /nobreak > nul
md %desktop%\%tmpdir%
xcopy %win10papperdir%\*.* %desktop%\%tmpdir% /s > nul
cd %desktop%\%tmpdir%
ren *.* *.jpg
::%errorlevel%
:aa
for /R %%s in (*) do (
    for /f "tokens=1,2 delims=: " %%a in ('%xnview%\nconvert.exe -quiet -info -ignore_errors %%s') do (
        if /i %%a equ Height if /i %%b equ 1080 (
            echo %%s
        ) else (
            del %%s
        )
    )
)
cd %desktop%

tips: windows 增加一条路由

解决连接vpn后,连接不到内网的问题

route -p add 10.13.0.0 MASK 255.255.248.0 10.10.8.1 # 所有10.13网段,都走10.10.8.1的网关
» 转载请注明来源:若我若鱼 » win10 保存锁屏壁纸

Leave a Reply

Your email address will not be published. Required fields are marked *

15 − 5 =