Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 25 Sep 2019 02:38:37 +0000
From:      bugzilla-noreply@freebsd.org
To:        bugs@FreeBSD.org
Subject:   [Bug 237538] [patch] cron: add log suppression and mail suppression for successful runs
Message-ID:  <bug-237538-227-kmJJDAe4AV@https.bugs.freebsd.org/bugzilla/>
In-Reply-To: <bug-237538-227@https.bugs.freebsd.org/bugzilla/>
References:  <bug-237538-227@https.bugs.freebsd.org/bugzilla/>

next in thread | previous in thread | raw e-mail | index | archive | help
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=3D237538

--- Comment #7 from commit-hook@freebsd.org ---
A commit references this bug:

Author: kevans
Date: Wed Sep 25 02:37:42 UTC 2019
New revision: 352668
URL: https://svnweb.freebsd.org/changeset/base/352668

Log:
  cron: add log suppression and mail suppression for successful runs

  This commit adds two new extensions to crontab, ported from OpenBSD:
  - -n: suppress mail on succesful run
  - -q: suppress logging of command execution

  The -q option appears decades old, but -n is relatively new. The
  original proposal by Job Snijder can be found here [1], and gives very
  convincing reasons for inclusion in base.

  This patch is a nearly identical port of OpenBSD cron for -q and -n
  features. It is written to follow existing conventions and style of the
  existing codebase.

  Example usage:

  # should only send email, but won't show up in log
  * * * * * -q date

  # should not send email
  * * * * * -n date

  # should not send email or log
  * * * * * -n -q date

  # should send email because of ping failure
  * * * * * -n -q ping -c 1 5.5.5.5

  [1]: https://marc.info/?l=3Dopenbsd-tech&m=3D152874866117948&w=3D2

  PR:           237538
  Submitted by: Naveen Nathan <freebsd_t.lastninja.net>
  Reviewed by:  bcr (manpages)
  MFC after:    1 week
  Differential Revision:        https://reviews.freebsd.org/D20046

Changes:
  head/usr.sbin/cron/cron/cron.h
  head/usr.sbin/cron/cron/do_command.c
  head/usr.sbin/cron/cron/popen.c
  head/usr.sbin/cron/crontab/crontab.5
  head/usr.sbin/cron/lib/entry.c

--=20
You are receiving this mail because:
You are the assignee for the bug.=



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?bug-237538-227-kmJJDAe4AV>