On 2020/08/03 13:50, Solene Rapenne wrote:
> On Mon, 3 Aug 2020 13:28:38 +0200
> Emil Engler <[email protected]>:
> 
> > ## Abstract
> > This patch adds an argument to sysupgrade(8) which makes it possible
> > to check if an upgrade is available, similar to "syspatch -c".
> > This works both, for snapshots and releases.
> > 
> > ## Usage
> > Add "-c" to sysupgrade.
> > If the script exits with a zero, an upgrade is available. If it fails
> > you are already on the newest version or an upgrade cannot be pulled
> > for whatever reason.
> > 
> > ## Motivation
> > I want a cronjob on my desktop (which is on -current) that checks
> > regularly if a new snapshot is available and notifies me if this is
> > the case. syspatch(8) already has such a feature, so why not add
> > one to sysupgrade? Also it could be useful on -stable and -release
> > systems.
> 
> it seems to me you could use this in your crontab
> 
> sysupgrade -n | grep "Already on last snapshot" || sh 
> send_mail_new_snasphot.sh
> 

That won't just check, it will stage the release for install on next boot.

Reply via email to