diff options
author | cvs2git <cvs2git> | 2010-12-27 00:04:45 +0000 |
---|---|---|
committer | cvs2git <cvs2git> | 2010-12-27 00:04:45 +0000 |
commit | c82d349f864e6bd9f96fd1156903bc1f7193a203 (patch) | |
tree | e117a87533656110b6acd56fc0ca64289892a9f5 /FS/bin/freeside-prune-applications | |
parent | 74e058c8a010ef6feb539248a550d0bb169c1e94 (diff) |
This commit was manufactured by cvs2svn to create tag 'TORRUS_1_0_9'.TORRUS_1_0_9
Diffstat (limited to 'FS/bin/freeside-prune-applications')
-rwxr-xr-x | FS/bin/freeside-prune-applications | 63 |
1 files changed, 0 insertions, 63 deletions
diff --git a/FS/bin/freeside-prune-applications b/FS/bin/freeside-prune-applications deleted file mode 100755 index d2b6efe0b..000000000 --- a/FS/bin/freeside-prune-applications +++ /dev/null @@ -1,63 +0,0 @@ -#!/usr/bin/perl -w - -use strict; -use vars qw($opt_d $opt_q $opt_v); # $opt_n instead of $opt_d? -use vars qw($DEBUG $DRY_RUN); -use Getopt::Std; -use FS::UID qw(adminsuidsetup checkeuid); -use FS::Misc::prune qw(prune_applications); - -die "Not running uid freeside!" unless checkeuid(); - -getopts("dq"); - -$DEBUG = !$opt_q; -#$DEBUG = $opt_v; - -$DRY_RUN = $opt_d; - -my $user = shift or die &usage; -my $dbh = adminsuidsetup($user); - -my $hashref = {}; - -$hashref->{dry_run} = 1 if $DRY_RUN; -$hashref->{debug} = 1 if $DEBUG; - -print join "\n", prune_applications($hashref); -print "\n" if $DRY_RUN; - -$dbh->commit or die $dbh->errstr; - -### - -sub usage { - die "Usage:\n freeside-prune-applications [ -d ] [ -q | -v ] user\n"; -} - -=head1 NAME - -freeside-prune-applications - Removes stray applications of credit, payment to - bills, refunds, etc. - -=head1 SYNOPSIS - - freeside-prune-applications [ -d ] [ -q | -v ] - -=head1 DESCRIPTION - -Reads your existing database schema and updates it to match the current schema, -adding any columns or tables necessary. - - [ -d ]: Dry run; display affected records (to STDOUT) only, but do not - remove them. - - [ -q ]: Run quietly. This may become the default at some point. - - [ -v ]: Run verbosely, sending debugging information to STDERR. This is the - current default. - -=head1 SEE ALSO - -=cut - |