There is now three variable values that I pass to 'tm'
Code:
/usr/local/ptmtimer/tm ${ENTRY} ${SND} ${MESSAGE}
Following Zigbert's method , I create a folder /usr/local/ptmtimer/
to hold the program but the app has to be launched from an executable
path so I create a small script just to launch the app.
________________________________
Posted: Thu 10 Mar 2011, 19:00 Post subject:
script loops a given number of sconds
I made a change to tm script to make it loop indefinitely
with a given period (in seconds). It might be useful to
someone who has an operation that must be done continually,
like checking a file. I'm not a programmer so
I don't know how this script works. I was just tinkering.
Code:
#!/bin/sh
#This script loops endlessly with a period of tsec
until [ -z 4 ]
do
tsec=9
n="0"
for ((i=0;i<=${tsec};i++)); do
n="$((${n} + 1))"
if [ "$n" == "${tsec}" ]; then
gxmessage "Hello Message"
fi
sleep 1
done
done
exit
____________________________________________ Last edited by don570 on Thu 10 Mar 2011, 19:10; edited 1 time in total
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