Introduction
Introduction Statistics Contact Development Disclaimer Help
index.md - sites - public wiki contents of suckless.org
git clone git://git.suckless.org/sites
Log
Files
Refs
---
index.md (472B)
---
1 autorefresh
2 ===========
3
4 Simple script to auto refresh surf pages.
5 Launch the script again to stop auto reloading (easy to use with dmenu)
6
7 #!/bin/sh
8 # Simple script to refresh surf page
9 # [email protected]
10
11 REFRESH=3
12 LOCKFILE=/tmp/surfrefresh.lock
13
14
15 if [ -e $LOCKFILE ]; then
16 echo "stop refreshing surf"
17 PID=$(cat $LOCKFILE)
18 rm $LOCKFILE
19 kill -KILL $PID
20 else
21 echo $$ > $LOCKFILE
22 while true; do
23 kill -HUP $1
24 sleep $REFRESH
25 done
26 fi
27 exit 0
You are viewing proxied material from suckless.org. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.