Welcome, guest! Login / Register - Why register?
Psst.. new poll here.
[email protected] webmail now available. Want one? Go here.
Cannot use outlook/hotmail/live here to register as they blocking our mail servers. #microsoftdeez
Obey the Epel!

Paste

Pasted as Bash by registered user uwe ( 11 years ago )
#!/bin/bash
if [ -f ~/.xlock ]; then exit; fi

if [ -f ~/bg/monitor_scc ]; then
    DISPLAY=:0 nitrogen --set-auto ~/bg/3840x1200/"$(ls ~/bg/3840x1200/ | shuf -n 1)"
    exit
else
    comb=~/bg/combined_3og
    first=~/bg/1920x1200
    sec=~/bg/1600x900
fi

pic1="$(ls $first/ | shuf -n 1)"
pic2="$(ls $sec/ | shuf -n 1)"

pic=$comb/"${pic1/.jpg}$pic2"

if [ ! -f "$pic" ]; then
    while [ $(ls $comb | wc -l) -gt 299 ]; do
        picr="$(ls $comb | shuf -n 1)"
        rm -f $comb/"$picr"
    done
    convert $first/"$pic1" $sec/"$pic2" +append "$pic"
fi

DISPLAY=:0 nitrogen --set-auto "$pic"

 

Revise this Paste

Your Name: Code Language: