Pschedule 1.1.6 - Task on time
backup a pupsave file
I describe how to backup a pupsave file at a scheduled time
at this page
http://www.murga-linux.com/puppy/viewto ... 279#567279
_________________________________________________
at this page
http://www.murga-linux.com/puppy/viewto ... 279#567279
_________________________________________________
Puppy Backup
I wrote about using Pschedule with Puppy Backup
HERE
This method will allow the user to back up his favorite folders overnite
on a regular basis.
It's quite simple and it just needs enough hard disk space
for the mirroring to be done completely and keep your
computer on overnite.
An external USB hard drive would be good for this purpose
and they're quite cheap now.
Mirroring of an entire partition to a folder is possible.
Make sure that the mirror folder is initially empty.
______________________________________________
HERE
This method will allow the user to back up his favorite folders overnite
on a regular basis.
It's quite simple and it just needs enough hard disk space
for the mirroring to be done completely and keep your
computer on overnite.
An external USB hard drive would be good for this purpose
and they're quite cheap now.
Mirroring of an entire partition to a folder is possible.
Make sure that the mirror folder is initially empty.
______________________________________________
Is it possible to filter out crond lines that begin with #
i.e. are obvious comments.
I'm trying to use pschedule with Porteus distribution
and it works surprising well except for all the comments.
I tried the following line to filter them out in
line 13 of func_cron_to_human
However I found that Delete key wouldn't work which is
important to me.
_______________________________________________
i.e. are obvious comments.
I'm trying to use pschedule with Porteus distribution
and it works surprising well except for all the comments.
I tried the following line to filter them out in
line 13 of func_cron_to_human
Code: Select all
cat /var/spool/cron/crontabs/$USER | sed "/^#/d" | sed -e "s/ /{ð®SSSđþ}/g" | sed -e "s/*/{ð®STARđþ}/g" > /tmp/pschedule-forloop
important to me.
_______________________________________________
I was able to fix the problem (in the Porteus distribution)
of comments showing in the list of jobs
with a simple addition of few lines of code
near start of 'pschedule' script so that the cleaning is performed
always at open ( actually the cleaning is only required once
but I didn't want to write complicated code)
The guest user doesn't have this problem fortunately.
__________________________________________________
of comments showing in the list of jobs
with a simple addition of few lines of code
near start of 'pschedule' script so that the cleaning is performed
always at open ( actually the cleaning is only required once
but I didn't want to write complicated code)
The guest user doesn't have this problem fortunately.
Code: Select all
# remove comment lines
killall -q crond
cat /var/spool/cron/crontabs/root | sed "/^#/d" > /tmp/pschedule_temp
mv -f /tmp/pschedule_temp /var/spool/cron/crontabs/root
crond
For those who are adventurous...
There is now Porteus versions of pschedule and puppy clock.
http://porteus.org/forum/viewtopic.php? ... 139#p10139
________________________________________
There is now Porteus versions of pschedule and puppy clock.
http://porteus.org/forum/viewtopic.php? ... 139#p10139
________________________________________
Hmmm... I'm unable to use pschedule-1.0.3.
The last one I was able to use is 1.0.2.
This new one gives the following error message:I have gtkdialog-0.8.0, but not gtkdialog4 (in fact I have been getting quite a collection gtkdialog, gtkdialog2, gtkdialog3-thunor, gtkdialog-0.8.0, gtkdialog3, gtkdialog-splash, where gtkdialog is actually a link to gtkdialog-0.8.0).
Can I make a request? It would be lovely if pschedule would ignore (but still display) comments. I use comments a lot in my crontab to remind me what stuff is for.
The last one I was able to use is 1.0.2.
This new one gives the following error message:
Code: Select all
ls: cannot access /locals/: No such file or directory
/usr/local/pschedule/pschedule: line 227: gtkdialog4: command not found
Can I make a request? It would be lovely if pschedule would ignore (but still display) comments. I use comments a lot in my crontab to remind me what stuff is for.
[color=blue]A life! Cool! Where can I download one of those from?[/color]
gtkdialog4 is Barrys link to gtkdialog-0.8.0. I will make it more flexible.
Regarding comments, could you be more specific - an example?
I am a bit blue when it comes to crontab. Only looked at it once - to make pSchedule. The old Gcrontab required gtk1 and we lost that when reaching Puppy 4.
Thank you
Sigmund
Regarding comments, could you be more specific - an example?
I am a bit blue when it comes to crontab. Only looked at it once - to make pSchedule. The old Gcrontab required gtk1 and we lost that when reaching Puppy 4.
Thank you
Sigmund
Oh, cool. I'll make a link to do that then. Thanks.
In my crontab - where all the date-time data is kept - I like to keep things grouped together by function, and use comments to describe them. It helps me understand later when I'm editing it.
Here is an example:A line beginning with a '#' is a comment line and I use it to separate all my non-repeating items from all the other items that do repeat. This is important because if you look at the two entries in my example above you'll notice the date part is exactly the same, but I want to remove one later and not the other, because this year I'm going to the birthday party on the day after the twins' actual birthday, whereas other years the party would be on another day even though the birthday itself doesn't change.
I add comments to my crontab file to help me remember other things while reading or editing it too. Blank lines are also important to help format the file in a human-readable way.
Another way I use comments is to stop cron reading expired entries. I don't delete them because it is often interesting and useful to be able to look back on obsolete entries.
Oh, and I should mention that 'alert' is just a simple shell script I made that plays a bell sound 5 times and puts a small dialog box up on the screen with a message in it. It is a convenient way of notifying myself of things.
In my crontab - where all the date-time data is kept - I like to keep things grouped together by function, and use comments to describe them. It helps me understand later when I'm editing it.
Here is an example:
Code: Select all
# one-off
# -------
0 9 17 11 * alert "Astar and Rawhinia's birthday party tomorrow"
# repeating
# ---------
0 9 17 11 * alert "Astar and Rawhinia's birthday"
I add comments to my crontab file to help me remember other things while reading or editing it too. Blank lines are also important to help format the file in a human-readable way.
Another way I use comments is to stop cron reading expired entries. I don't delete them because it is often interesting and useful to be able to look back on obsolete entries.
Oh, and I should mention that 'alert' is just a simple shell script I made that plays a bell sound 5 times and puts a small dialog box up on the screen with a message in it. It is a convenient way of notifying myself of things.
Last edited by miriam on Mon 22 Oct 2012, 23:28, edited 1 time in total.
[color=blue]A life! Cool! Where can I download one of those from?[/color]
Shinobar puts the following code in his apps.
I have been doing the same recently.
It allows the scripts to run on more distributions
________________________________________
I have been doing the same recently.
It allows the scripts to run on more distributions
Code: Select all
for P in gtkdialog4 gtkdialog3 gtkdialog; do
GTKDIALOG=$(which $P) && break
done
Yes, I see. I will improve this, but the above code will not work as gtkdialog3 will not run pSchedule and I would switch the order to run gtkdialog if available. I assume that gtkdialog will be the latest.don570 wrote:Shinobar puts the following code in his apps.
I have been doing the same recently.
It allows the scripts to run on more distributions
________________________________________Code: Select all
for P in gtkdialog4 gtkdialog3 gtkdialog; do GTKDIALOG=$(which $P) && break done
Sigmund
When I installed version 1.1.1 in the distro Carolina
I got a strange warning that 'cron gtkdialog' was needed.
It seems to be working allright. I'll continue to test with version 1.1.2.
EDIT: other apps are showing the same warning when
I install in Carolina so it must be a bug in Carloina
_________________________________________________
I got a strange warning that 'cron gtkdialog' was needed.
It seems to be working allright. I'll continue to test with version 1.1.2.
EDIT: other apps are showing the same warning when
I install in Carolina so it must be a bug in Carloina
_________________________________________________