#!/bin/bash let n=0 files=($HOME/wallpapers/*.jpg) count=${#files[@]} while [ 1 ] do let "n=n%$count" file="${files[$n]}" echo "switch to $file" feh --bg-max "$file" & let n=n+1 sleep 5s done
最近发现王者荣耀的壁纸很精美,就写了个自动更换壁纸的脚本