[freeside-commits] branch FREESIDE_4_BRANCH updated. a4617b1335279278b734ec2ed7f63c93478950a0
Ivan
ivan at 420.am
Sat Apr 1 13:20:21 PDT 2017
The branch, FREESIDE_4_BRANCH has been updated
via a4617b1335279278b734ec2ed7f63c93478950a0 (commit)
from a8de3642c65a465b0969e7b443c89e8aa3369ba1 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit a4617b1335279278b734ec2ed7f63c93478950a0
Author: Ivan Kohler <ivan at freeside.biz>
Date: Sat Apr 1 13:20:17 2017 -0700
add option to disable backup so two runs of freeside-daily with -m don't write to the same file
diff --git a/FS/bin/freeside-daily b/FS/bin/freeside-daily
index 1d2d913..233e162 100755
--- a/FS/bin/freeside-daily
+++ b/FS/bin/freeside-daily
@@ -8,7 +8,7 @@ use FS::Log;
&untaint_argv; #what it sounds like (eww)
use vars qw(%opt);
-getopts("p:a:d:vl:sy:nmrkg:o", \%opt);
+getopts("p:a:d:vl:sy:nmrkg:ox", \%opt);
my $user = shift or die &usage;
adminsuidsetup $user;
@@ -96,9 +96,9 @@ use FS::Cron::cleanup qw( cleanup cleanup_before_backup );
cleanup_before_backup();
#backup should be last
-#you can skip this just by not having the config
+#you can skip this just by not having the config (or with the -x option)
use FS::Cron::backup qw(backup);
-backup();
+backup() unless $opt{'x'};
#except we'd rather not start cleanup jobs until the backup is done
cleanup( quiet => !$opt{'v'} );
@@ -119,7 +119,7 @@ sub untaint_argv {
}
sub usage {
- die "Usage:\n\n freeside-daily [ -d 'date' ] [ -y days ] [ -a agentnum,agentnum,... ] [ -s ] [ -v ] [ -l level ] [ -m ] [ -k ] user [ custnum custnum ... ]\n";
+ die "Usage:\n\n freeside-daily [ -d 'date' ] [ -y days ] [ -a agentnum,agentnum,... ] [ -s ] [ -v ] [ -l level ] [ -m ] [ -k ] [ -x ] user [ custnum custnum ... ]\n";
}
###
@@ -175,6 +175,8 @@ the bill and collect methods of a cust_main object. See L<FS::cust_main>.
-k: skip notify_flat_delay
+ -x: skip backup
+
user: Typically "fs_daily"
custnum: if one or more customer numbers are specified, only bills those
-----------------------------------------------------------------------
Summary of changes:
FS/bin/freeside-daily | 10 ++++++----
1 file changed, 6 insertions(+), 4 deletions(-)
More information about the freeside-commits
mailing list