#!/bin/sh for DISPLAY in $(swaymsg -t get_outputs -r | grep name | cut -d \" -f 4); do PIC=$(find ~/pix | shuf | head -n 1) swaybg --output "${DISPLAY}" -i "${PIC}" -m fill & done