Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Thu 24 Apr 2014, 02:50
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » REQUESTS
simple wbar refresh code
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 1 [3 Posts]  
Author Message
nilsonmorales


Joined: 15 Apr 2011
Posts: 420
Location: El salvador

PostPosted: Tue 15 Oct 2013, 21:00    Post subject:  simple wbar refresh code  

i have no experience in bash or any programing lang just looking for a simple script to refresh the wbar when change the wallpaper
i saw this code

Code:
#!/bin/bash

shopt -s nullglob
 
cd $HOME/Wallpapers

while true; do
   files=()
   for i in *.jpg *.png; do
      [[ -f $i ]] && files+=("$i")
   done
   range=${#files[@]}

   ((range)) && feh --bg-scale "${files[RANDOM % range]}"

   # Restart wbar,if already running
   [`pidof wbar`] && killall wbar && wbar &

   sleep 10m
done


how can i use the [`pidof wbar`] && killall wbar && wbar & to refresh the wbar when change the wallpaper
thx in advance .

_________________
My blog


Back to top
View user's profile Send private message MSN Messenger 
rhadon


Joined: 27 Mar 2008
Posts: 1291
Location: Germany

PostPosted: Wed 16 Oct 2013, 01:36    Post subject:  

Hi nilsonmorales,

maybe this helps?

Rolf

_________________
Ich verwende "frugal", und das ist gut so. Wink
Raspberry Pi without Puppy? No, thanks.
Back to top
View user's profile Send private message 
nilsonmorales


Joined: 15 Apr 2011
Posts: 420
Location: El salvador

PostPosted: Wed 16 Oct 2013, 14:07    Post subject:  

I appreciate your help, unfortunately did not work
I think I need to add some code in the nathan wallpaper
anyway thank you.

_________________
My blog


Back to top
View user's profile Send private message MSN Messenger 
Display posts from previous:   Sort by:   
Page 1 of 1 [3 Posts]  
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » REQUESTS
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0377s ][ Queries: 11 (0.0044s) ][ GZIP on ]