View Single Post
  #7   (View Single Post)  
Old 29th January 2017
Head_on_a_Stick's Avatar
Head_on_a_Stick Head_on_a_Stick is offline
Real Name: Matthew
Bitchy Nerd Elitist
 
Join Date: Dec 2015
Location: London
Posts: 461
Default

Quote:
Originally Posted by e1-531g View Post
Code:
#!/bin/ksh

typeset -i ILOSC_TAPET=4
typeset -i losowa_liczba=$(( ( RANDOM % ${ILOSC_TAPET} ) + 1 ))
/usr/local/bin/feh --bg-scale /home/open/tapety/z_logo/${losowa_liczba}.jpg
This works as well:
Code:
/usr/local/bin/feh --bg-scale --randomize /home/open/tapety/z_logo/*.jpg


EDIT: also, rather than:
Code:
eval `cat $HOME/.fehbg`
This can be used instead:
Code:
sh "$HOME/.fehbg"
Thanks for the guide shep, it is very useful

Last edited by Head_on_a_Stick; 29th January 2017 at 05:32 PM. Reason: added /*.jpg then added actual EDIT
Reply With Quote