Bug 24526: Add the confirm flag to the cronjob files
authorJonathan Druart <jonathan.druart@bugs.koha-community.org>
Thu, 6 Feb 2020 10:33:12 +0000 (11:33 +0100)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Mon, 10 Feb 2020 10:13:35 +0000 (10:13 +0000)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

debian/koha-common.cron.daily
misc/cronjobs/automatic_renewals.pl
misc/cronjobs/crontab.example

index 63eb070..b458cd9 100644 (file)
@@ -15,7 +15,7 @@
 # You should have received a copy of the GNU General Public License
 # along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
-koha-foreach --chdir --enabled /usr/share/koha/bin/cronjobs/automatic_renewals.pl
+koha-foreach --chdir --enabled /usr/share/koha/bin/cronjobs/automatic_renewals.pl -c
 koha-foreach --chdir --enabled /usr/share/koha/bin/cronjobs/fines.pl
 koha-foreach --chdir --enabled --email /usr/share/koha/bin/cronjobs/overdue_notices.pl -t
 koha-foreach --chdir --enabled --email /usr/share/koha/bin/cronjobs/advance_notices.pl -c
index 5995769..d7bc5a1 100755 (executable)
@@ -23,10 +23,10 @@ automatic_renewals.pl - cron script to renew loans
 
 =head1 SYNOPSIS
 
-./automatic_renewals.pl [--send-notices]
+./automatic_renewals.pl [-c|--confirm] [--send-notices]
 
 or, in crontab:
-0 3 * * * automatic_renewals.pl
+0 3 * * * automatic_renewals.pl -c
 
 =head1 DESCRIPTION
 
@@ -44,11 +44,11 @@ Send AUTO_RENEWALS notices to patrons if the auto renewal has been done.
 
 Note that this option does not support digest yet.
 
-=item B<--verbose>
+=item B<-v|--verbose>
 
 Print report to standard out.
 
-=item B<--confirm>
+=item B<-c|--confirm>
 
 Without this parameter no changes will be made
 
index 80c1d9e..5326a47 100644 (file)
@@ -48,7 +48,7 @@ KOHA_CRON_PATH = /usr/share/koha/bin/cronjobs
 
 # AUTOMATIC RENEWAL + FINES + OVERDUE NOTICES
 # Sequence is important - renew what can be renewed, charge fines for the rest, print fine amount into overdue notices
-5    1 * * *  __KOHA_USER__ $KOHA_CRON_PATH/automatic_renewals.pl; $KOHA_CRON_PATH/fines.pl; $KOHA_CRON_PATH/overdue_notices.pl -t
+5    1 * * *  __KOHA_USER__ $KOHA_CRON_PATH/automatic_renewals.pl -c; $KOHA_CRON_PATH/fines.pl; $KOHA_CRON_PATH/overdue_notices.pl -t
 
 # ADVANCE NOTICES
 10   1 * * *  __KOHA_USER__  $KOHA_CRON_PATH/advance_notices.pl -c