View Single Post
Old 02-24-2014, 02:35 AM   #34
eschwartz
Ex-Helpdesk Junkie
eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.eschwartz ought to be getting tired of karma fortunes by now.
 
eschwartz's Avatar
 
Posts: 19,421
Karma: 85400180
Join Date: Nov 2012
Location: The Beaten Path, USA, Roundworld, This Side of Infinity
Device: Kindle Touch fw5.3.7 (Wifi only)
I believe you will have to make sure the task is run as the root user or else it will silently fail when you don't supply the password.

Save the following attachment in your home folder. Extract it from the zipped compression (right-click and "Extract Here") then open a terminal and run these two commands to a) move the upgrade script to the executable directory and b) make the script belong to root:

Code:
sudo mv calibre-upgrade.sh /usr/bin/calibre-upgrade.sh
sudo chown root:root /usr/bin/calibre-upgrade.sh
Then run this:
Code:
sudo EDITOR="gedit" crontab -e
This will open the root crontab in the graphical text editor. I figured this is not the time for you to start learning nano or (heaven forbid) vim.

EDIT: Because vim is a complicated sysadmin tool, not because its a bad editor.

paste this line on the bottom, on a new line:

Code:
0 6 * * 5 /usr/bin/calibre-upgrade.sh > /dev/null 2>&1
Then press enter, as crontab must end with a newline or it goes kablooey.

Save the file, and it will update your crontab and install the auto-update code.

Install "anacron" in the software center, and missed jobs should be carried out shortly after you reboot.
Attached Files
File Type: gz calibre-upgrade.sh.gz (398 Bytes, 168 views)

Last edited by eschwartz; 02-24-2014 at 10:04 PM.
eschwartz is offline