What is wrong with Kovid's one-liner?
There is a calibre-upgrade.sh here
Quote:
Originally Posted by eschwartz
There is a new install command, so make sure to update calibre-upgrade.sh everyone!
(the old version has been kept up for backwards compatibility, but we wouldn't be in this thread if we were content with plebeian methodologies.  )
Code:
#!/bin/bash
calibre-debug -c "import urllib as u; from calibre.constants import numeric_version; raise SystemExit(int(numeric_version < (tuple(map(int, u.urlopen('http://calibre-ebook.com/downloads/latest_version').read().split('.'))))))"
UP_TO_DATE=$?
if [ $UP_TO_DATE = 0 ]; then
echo "Calibre is up-to-date"
else
calibre --shutdown-running-calibre
killall calibre-server
sudo -v; wget -nv -O- https://github.com/kovidgoyal/calibre/raw/master/setup/linux-installer.py | sudo python -c "import sys; main=lambda:sys.stderr.write('Download failed\n'); exec(sys.stdin.read()); main()"
fi
And we have more goodies, like calibre-uninstall, and an "isolated" updater.
|
This will check for an updated version, and then it is a simple matter of running calbre-upgrade.sh in a weekly cron job. It compares calibre --version to the website version, and calls Kovid's one-liner. Nice and simple.

Why didn't we make a sticky for that anyway?