diff options
| author | fukachan <fukachan> | 2004-06-26 11:47:55 +0000 |
|---|---|---|
| committer | fukachan <fukachan> | 2004-06-26 11:47:55 +0000 |
| commit | 06114f7bdcc1cf0bfd5a33a73405f607bbbfe7dd (patch) | |
| tree | 88efd68768f0a4254851280c908a8642590df808 /fml/lib/FML/Command/Admin | |
| parent | 8a4ad321fb933d12ba65adf4354b3fd8f4108981 (diff) | |
| download | fml8-06114f7bdcc1cf0bfd5a33a73405f607bbbfe7dd.tar.gz fml8-06114f7bdcc1cf0bfd5a33a73405f607bbbfe7dd.tar.bz2 fml8-06114f7bdcc1cf0bfd5a33a73405f607bbbfe7dd.zip | |
overhaul: fix comments, messages and style.
Diffstat (limited to 'fml/lib/FML/Command/Admin')
| -rw-r--r-- | fml/lib/FML/Command/Admin/addadmin.pm | 23 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/addmember.pm | 26 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/addmoderator.pm | 10 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/addrecipient.pm | 24 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/check.pm | 24 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/deladmin.pm | 14 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/delmoderator.pm | 14 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/dir.pm | 14 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/error.pm | 14 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/file.pm | 17 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/flushq.pm | 8 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/mailq.pm | 12 | ||||
| -rw-r--r-- | fml/lib/FML/Command/Admin/summary.pm | 11 |
13 files changed, 109 insertions, 102 deletions
diff --git a/fml/lib/FML/Command/Admin/addadmin.pm b/fml/lib/FML/Command/Admin/addadmin.pm index 215bf78a..b6bc7ba9 100644 --- a/fml/lib/FML/Command/Admin/addadmin.pm +++ b/fml/lib/FML/Command/Admin/addadmin.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: addadmin.pm,v 1.18 2004/02/15 04:38:27 fukachan Exp $ +# $FML: addadmin.pm,v 1.19 2004/04/28 04:10:35 fukachan Exp $ # package FML::Command::Admin::addadmin; @@ -15,7 +15,7 @@ use Carp; =head1 NAME -FML::Command::Admin::addadmin - add a new remote administrator +FML::Command::Admin::addadmin - add a new remote administrator. =head1 SYNOPSIS @@ -32,7 +32,7 @@ add a new remote administrator mail address. =cut -# Descriptions: standard constructor +# Descriptions: constructor. # Arguments: OBJ($self) # Side Effects: none # Return Value: OBJ @@ -45,14 +45,14 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 1;} -# Descriptions: lock channel +# Descriptions: lock channel. # Arguments: none # Side Effects: none # Return Value: STR @@ -73,9 +73,9 @@ sub verify_syntax } -# Descriptions: addadmin a new user +# Descriptions: add a new remote administrator mail address. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) -# Side Effects: update $member_map $recipient_map +# Side Effects: update proper $member_map and $recipient_map. # Return Value: none sub process { @@ -86,11 +86,12 @@ sub process # XXX We should always add/rewrite only $primary_*_map maps via # XXX command mail, CUI and GUI. - # XXX Rewriting of maps not $primary_*_map is + # XXX Rewriting of maps excluding $primary_*_map is # XXX 1) may be not writable. - # XXX 2) ambigous and dangerous + # XXX 2) ambiguous and dangerous # XXX since the map is under controlled by other module. - # XXX for example, one of member_maps is under admin_member_maps. + # XXX For example, one of $member_maps is $primary_admin_member_map. + # XXX So $member_maps contains two different regions. my $member_map = $config->{ primary_admin_member_map }; my $recipient_map = $config->{ primary_admin_recipient_map }; @@ -119,7 +120,7 @@ sub process } -# Descriptions: cgi menu to add a new user +# Descriptions: cgi menu to add a new remote administrator. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: update $member_map $recipient_map # Return Value: none diff --git a/fml/lib/FML/Command/Admin/addmember.pm b/fml/lib/FML/Command/Admin/addmember.pm index 23c556da..f3d2d43c 100644 --- a/fml/lib/FML/Command/Admin/addmember.pm +++ b/fml/lib/FML/Command/Admin/addmember.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: on.pm,v 1.19 2004/04/30 13:38:05 fukachan Exp $ +# $FML: addmember.pm,v 1.1 2004/05/01 05:02:04 fukachan Exp $ # package FML::Command::Admin::addmember; @@ -15,7 +15,7 @@ use Carp; =head1 NAME -FML::Command::Admin::addmember - add member (member only) +FML::Command::Admin::addmember - add member (member only). =head1 SYNOPSIS @@ -32,7 +32,7 @@ change delivery mode from digest to real time. =cut -# Descriptions: constructor +# Descriptions: constructor. # Arguments: OBJ($self) # Side Effects: none # Return Value: OBJ @@ -45,14 +45,14 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 1;} -# Descriptions: lock channel +# Descriptions: lock channel. # Arguments: none # Side Effects: none # Return Value: STR @@ -87,18 +87,18 @@ sub process # XXX We should always add/rewrite only $primary_*_map maps via # XXX command mail, CUI and GUI. - # XXX Rewriting of maps not $primary_*_map is + # XXX Rewriting of maps excluding $primary_*_map is # XXX 1) may be not writable. # XXX 2) ambigous and dangerous # XXX since the map is under controlled by other module. - # XXX for example, one of member_maps is under admin_member_maps. + # XXX for example, $member_maps contains different classes. my $member_map = $config->{ primary_member_map }; # fundamental check - croak("address not defined") unless defined $address; - croak("\$member_map not defined") unless defined $member_map; - croak("address not specified") unless $address; - croak("\$member_map not specified") unless $member_map; + croak("address not defined") unless defined $address; + croak("member_map not defined") unless defined $member_map; + croak("address not specified") unless $address; + croak("member_map not specified") unless $member_map; # FML::User::Control specific parameters my $uc_args = { @@ -108,7 +108,7 @@ sub process my $r = ''; # diag: $member_map should not have this user. - my $msg_args = { + my $msg_args = { _arg_address => $address, }; if ($cred->has_address_in_map($member_map, $config, $address)) { @@ -131,7 +131,7 @@ sub process } -# Descriptions: show cgi menu for on +# Descriptions: show cgi menu for adding a member. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: update $member_map # Return Value: none diff --git a/fml/lib/FML/Command/Admin/addmoderator.pm b/fml/lib/FML/Command/Admin/addmoderator.pm index f7d4c0d9..96a9a285 100644 --- a/fml/lib/FML/Command/Admin/addmoderator.pm +++ b/fml/lib/FML/Command/Admin/addmoderator.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: addmoderator.pm,v 1.13 2004/02/15 04:38:27 fukachan Exp $ +# $FML: addmoderator.pm,v 1.14 2004/04/28 04:10:35 fukachan Exp $ # package FML::Command::Admin::addmoderator; @@ -15,7 +15,7 @@ use Carp; =head1 NAME -FML::Command::Admin::addmoderator - add a new moderator +FML::Command::Admin::addmoderator - add a new moderator. =head1 SYNOPSIS @@ -32,7 +32,7 @@ add a new moderator address. =cut -# Descriptions: standard constructor +# Descriptions: constructor. # Arguments: OBJ($self) # Side Effects: none # Return Value: OBJ @@ -45,14 +45,14 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 1;} -# Descriptions: lock channel +# Descriptions: lock channel. # Arguments: none # Side Effects: none # Return Value: STR diff --git a/fml/lib/FML/Command/Admin/addrecipient.pm b/fml/lib/FML/Command/Admin/addrecipient.pm index 0afc0054..142777a6 100644 --- a/fml/lib/FML/Command/Admin/addrecipient.pm +++ b/fml/lib/FML/Command/Admin/addrecipient.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: on.pm,v 1.19 2004/04/30 13:38:05 fukachan Exp $ +# $FML: addrecipient.pm,v 1.1 2004/05/01 05:02:04 fukachan Exp $ # package FML::Command::Admin::addrecipient; @@ -15,7 +15,7 @@ use Carp; =head1 NAME -FML::Command::Admin::addrecipient - add recipient (recipient only) +FML::Command::Admin::addrecipient - add recipient (recipient only). =head1 SYNOPSIS @@ -32,7 +32,7 @@ change delivery mode from digest to real time. =cut -# Descriptions: constructor +# Descriptions: constructor. # Arguments: OBJ($self) # Side Effects: none # Return Value: OBJ @@ -45,14 +45,14 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 1;} -# Descriptions: lock channel +# Descriptions: lock channel. # Arguments: none # Side Effects: none # Return Value: STR @@ -91,14 +91,14 @@ sub process # XXX 1) may be not writable. # XXX 2) ambigous and dangerous # XXX since the map is under controlled by other module. - # XXX for example, one of member_maps is under admin_member_maps. + # XXX for example, $member_maps contains different classes. my $recipient_map = $config->{ primary_recipient_map }; # fundamental check - croak("address not defined") unless defined $address; - croak("\$recipient_map not defined") unless defined $recipient_map; - croak("address not specified") unless $address; - croak("\$recipient_map not specified") unless $recipient_map; + croak("address not defined") unless defined $address; + croak("recipient_map not defined") unless defined $recipient_map; + croak("address not specified") unless $address; + croak("recipient_map not specified") unless $recipient_map; # FML::User::Control specific parameters my $uc_args = { @@ -108,7 +108,7 @@ sub process my $r = ''; # diag: $recipient_map should not have this user. - my $msg_args = { + my $msg_args = { _arg_address => $address, }; if ($cred->has_address_in_map($recipient_map, $config, $address)) { @@ -131,7 +131,7 @@ sub process } -# Descriptions: show cgi menu for on +# Descriptions: show cgi menu for adding a recipient. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: update $recipient_map # Return Value: none diff --git a/fml/lib/FML/Command/Admin/check.pm b/fml/lib/FML/Command/Admin/check.pm index 7ad83738..2b0e6454 100644 --- a/fml/lib/FML/Command/Admin/check.pm +++ b/fml/lib/FML/Command/Admin/check.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: check.pm,v 1.12 2004/02/24 14:36:52 fukachan Exp $ +# $FML: check.pm,v 1.13 2004/04/23 04:10:29 fukachan Exp $ # package FML::Command::Admin::check; @@ -28,7 +28,7 @@ cheap diagnostic check. =cut -# Descriptions: standard constructor +# Descriptions: constructor. # Arguments: OBJ($self) # Side Effects: none # Return Value: OBJ @@ -41,12 +41,14 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 0;} + + # check rules my @rules = qw( check_ml_home_dir @@ -97,7 +99,7 @@ sub check_ml_home_dir } -# Descriptions: check spool permission +# Descriptions: check spool permission. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: fix permission # Return Value: none @@ -130,7 +132,7 @@ sub check_spool_dir -# Descriptions: check html_archive permission +# Descriptions: check html_archive permission. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: fix permission # Return Value: none @@ -146,20 +148,20 @@ sub check_html_archive_dir } -# Descriptions: return directory mode +# Descriptions: return directory mode. # Arguments: STR($dir) # Side Effects: none # Return Value: NUM(%o) sub _dir_mode { my ($dir) = @_; - my ($dev,$ino,$mode) = stat($dir); + my ($dev, $ino, $mode) = stat($dir); return ($mode & 0777); } -# Descriptions: check if $dir mode is 0700 +# Descriptions: check if $dir mode is 0700. # Arguments: STR($dir) # Side Effects: none # Return Value: NUM(1 or 0) @@ -173,7 +175,7 @@ sub _is_700 } -# Descriptions: check if $dir mode is 0770 +# Descriptions: check if $dir mode is 0770. # Arguments: STR($dir) # Side Effects: none # Return Value: NUM(1 or 0) @@ -187,7 +189,7 @@ sub _is_770 } -# Descriptions: check if $dir mode is 0777 +# Descriptions: check if $dir mode is 0777. # Arguments: STR($dir) # Side Effects: none # Return Value: NUM(1 or 0) @@ -201,7 +203,7 @@ sub _is_777 } -# Descriptions: check if $dir mode is 0755 +# Descriptions: check if $dir mode is 0755. # Arguments: STR($dir) # Side Effects: none # Return Value: NUM(1 or 0) diff --git a/fml/lib/FML/Command/Admin/deladmin.pm b/fml/lib/FML/Command/Admin/deladmin.pm index 1f8ec128..c770ac3b 100644 --- a/fml/lib/FML/Command/Admin/deladmin.pm +++ b/fml/lib/FML/Command/Admin/deladmin.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: deladmin.pm,v 1.17 2004/02/15 04:38:28 fukachan Exp $ +# $FML: deladmin.pm,v 1.18 2004/04/28 04:10:36 fukachan Exp $ # package FML::Command::Admin::deladmin; @@ -15,7 +15,7 @@ use Carp; =head1 NAME -FML::Command::Admin::deladmin - remove the specified remote administrator +FML::Command::Admin::deladmin - remove the specified remote administrator. =head1 SYNOPSIS @@ -32,7 +32,7 @@ remove the specified remote administrator. =cut -# Descriptions: standard constructor +# Descriptions: constructor. # Arguments: OBJ($self) # Side Effects: none # Return Value: OBJ @@ -45,14 +45,14 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 1;} -# Descriptions: lock channel +# Descriptions: lock channel. # Arguments: none # Side Effects: none # Return Value: STR @@ -88,7 +88,7 @@ sub process # XXX 1) may be not writable. # XXX 2) ambigous and dangerous # XXX since the map is under controlled by other module. - # XXX for example, one of member_maps is under admin_member_maps. + # XXX For example, $member_maps contains different classes. my $member_map = $config->{ 'primary_admin_member_map' }; my $recipient_map = $config->{ 'primary_admin_recipient_map' }; my $options = $command_args->{ options }; @@ -121,7 +121,7 @@ sub process } -# Descriptions: show cgi menu to remove the remote administrator. +# Descriptions: show cgi menu to remove the specified remote administrator. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: update $member_map $recipient_map # Return Value: none diff --git a/fml/lib/FML/Command/Admin/delmoderator.pm b/fml/lib/FML/Command/Admin/delmoderator.pm index 0bfe24be..2b508dab 100644 --- a/fml/lib/FML/Command/Admin/delmoderator.pm +++ b/fml/lib/FML/Command/Admin/delmoderator.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: delmoderator.pm,v 1.16 2004/02/15 04:38:28 fukachan Exp $ +# $FML: delmoderator.pm,v 1.17 2004/04/28 04:10:36 fukachan Exp $ # package FML::Command::Admin::delmoderator; @@ -15,7 +15,7 @@ use Carp; =head1 NAME -FML::Command::Admin::delmoderator - remove the specified moderator +FML::Command::Admin::delmoderator - remove the specified moderator. =head1 SYNOPSIS @@ -32,7 +32,7 @@ remove the specified moderator. =cut -# Descriptions: standard constructor +# Descriptions: constructor. # Arguments: OBJ($self) # Side Effects: none # Return Value: OBJ @@ -45,14 +45,14 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 1;} -# Descriptions: lock channel +# Descriptions: lock channel. # Arguments: none # Side Effects: none # Return Value: STR @@ -90,7 +90,7 @@ sub process # XXX 1) may be not writable. # XXX 2) ambigous and dangerous # XXX since the map is under controlled by other module. - # XXX for example, one of member_maps is under admin_member_maps. + # XXX For example, $member_maps contains different classes. my $member_map = $config->{ 'primary_moderator_member_map' }; my $recipient_map = $config->{ 'primary_moderator_recipient_map' }; @@ -121,7 +121,7 @@ sub process } -# Descriptions: show cgi menu to remove the moderator. +# Descriptions: show cgi menu to remove the specified moderator. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: update $member_map $recipient_map # Return Value: none diff --git a/fml/lib/FML/Command/Admin/dir.pm b/fml/lib/FML/Command/Admin/dir.pm index b8329b00..6e5cc334 100644 --- a/fml/lib/FML/Command/Admin/dir.pm +++ b/fml/lib/FML/Command/Admin/dir.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: dir.pm,v 1.16 2004/01/02 14:45:04 fukachan Exp $ +# $FML: dir.pm,v 1.17 2004/06/24 11:31:25 fukachan Exp $ # package FML::Command::Admin::dir; @@ -15,7 +15,7 @@ use Carp; =head1 NAME -FML::Command::Admin::dir - show "ls -l" results +FML::Command::Admin::dir - show "ls -l" results. =head1 SYNOPSIS @@ -32,7 +32,7 @@ show "ls -l" results. =cut -# Descriptions: standard constructor +# Descriptions: constructor. # Arguments: OBJ($self) # Side Effects: none # Return Value: OBJ @@ -45,16 +45,16 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 0;} -# Descriptions: show the result by "ls -l" +# Descriptions: show the result by "ls -l". # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) -# Side Effects: update $member_map $recipient_map +# Side Effects: update $member_map and $recipient_map. # Return Value: none sub process { @@ -72,6 +72,7 @@ sub process for my $x (@$options) { # XXX-TODO: correct? we restrict the "ls" option pattern here. if ($safe->regexp_match('directory', $x)) { + # XXX-TODO: allow plural options ? $du_args->{ opt_ls } = $x; } else { @@ -80,6 +81,7 @@ sub process } if ($curproc->is_cui_process()) { + # --send-to option. $recipient = $curproc->command_specific_recipient() || ''; $command_args->{ _recipient } = $recipient; } diff --git a/fml/lib/FML/Command/Admin/error.pm b/fml/lib/FML/Command/Admin/error.pm index 5211e33d..769ce0ed 100644 --- a/fml/lib/FML/Command/Admin/error.pm +++ b/fml/lib/FML/Command/Admin/error.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: error.pm,v 1.12 2004/04/20 03:32:47 fukachan Exp $ +# $FML: error.pm,v 1.13 2004/05/22 06:19:51 fukachan Exp $ # package FML::Command::Admin::error; @@ -15,7 +15,7 @@ use Carp; =head1 NAME -FML::Command::Admin::error - show error status +FML::Command::Admin::error - show statics/status of error mails. =head1 SYNOPSIS @@ -29,7 +29,7 @@ show error status. =head2 process($curproc, $command_args) -call error status list generator. +call error status generator. =cut @@ -47,21 +47,21 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 1;} -# Descriptions: lock channel +# Descriptions: return lock channel. # Arguments: none # Side Effects: none # Return Value: STR sub lock_channel { return undef;} -# Descriptions: list up status of error messages +# Descriptions: list up status of error messages. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: update $recipient_map # Return Value: none @@ -110,7 +110,7 @@ sub _fmlerror } -# Descriptions: +# Descriptions: show result by the specified analyzer. # Arguments: OBJ($self) OBJ($curproc) OBJ($error) STR($fp) # Side Effects: none # Return Value: none diff --git a/fml/lib/FML/Command/Admin/file.pm b/fml/lib/FML/Command/Admin/file.pm index a780d572..c8a1dacb 100644 --- a/fml/lib/FML/Command/Admin/file.pm +++ b/fml/lib/FML/Command/Admin/file.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: file.pm,v 1.16 2004/01/01 08:48:39 fukachan Exp $ +# $FML: file.pm,v 1.17 2004/01/01 23:52:12 fukachan Exp $ # package FML::Command::Admin::file; @@ -15,7 +15,7 @@ use Carp; =head1 NAME -FML::Command::Admin::file - functions for file operations +FML::Command::Admin::file - functions for file operations. =head1 SYNOPSIS @@ -45,28 +45,28 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 1;} -# Descriptions: lock channel +# Descriptions: lock channel. # Arguments: none # Side Effects: none # Return Value: STR sub lock_channel { return 'command_serialize';} -# Descriptions: needs "command subcommand parameters" style or not +# Descriptions: needs "command subcommand parameters" style or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub is_subcommand_style { 1;} -# Descriptions: wrapper for file operations +# Descriptions: dispatcher of file subcommand operations. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: file is created, renamed and removed # Return Value: none @@ -75,7 +75,7 @@ sub process my ($self, $curproc, $command_args) = @_; my $config = $curproc->config(); my $log_file = $config->{ log_file }; - my $options = $command_args->{ options }; + my $options = $command_args->{ options } || []; my $du_args = {}; my @argv = (); @@ -90,6 +90,7 @@ sub process $subcommand eq 'unlink') { for my $x (@args) { if ($safe->regexp_match('file', $x)) { + # XXX-TODO: we shoul allow plural ? push(@argv, $x); } } @@ -105,7 +106,7 @@ sub process } -# Descriptions: show cgi menu (dummy) +# Descriptions: show cgi menu (dummy). # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: update $member_map $recipient_map # Return Value: none diff --git a/fml/lib/FML/Command/Admin/flushq.pm b/fml/lib/FML/Command/Admin/flushq.pm index 09437d83..fe35a31f 100644 --- a/fml/lib/FML/Command/Admin/flushq.pm +++ b/fml/lib/FML/Command/Admin/flushq.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: @template.pm,v 1.8 2004/01/01 07:29:27 fukachan Exp $ +# $FML: flushq.pm,v 1.1 2004/05/19 13:48:21 fukachan Exp $ # package FML::Command::Admin::flushq; @@ -14,7 +14,7 @@ use Carp; =head1 NAME -FML::Command::Admin::flushq - what is this +FML::Command::Admin::flushq - flush outgoing mail queue. =head1 SYNOPSIS @@ -39,14 +39,14 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 0;} -# Descriptions: change delivery mode from real time to digest. +# Descriptions: flush outgoing mail queue. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: update $recipient_map # Return Value: none diff --git a/fml/lib/FML/Command/Admin/mailq.pm b/fml/lib/FML/Command/Admin/mailq.pm index aa111536..5863622a 100644 --- a/fml/lib/FML/Command/Admin/mailq.pm +++ b/fml/lib/FML/Command/Admin/mailq.pm @@ -1,10 +1,10 @@ #-*- perl -*- # -# Copyright (C) 2003 Ken'ichi Fukamachi +# Copyright (C) 2003,2004 Ken'ichi Fukamachi # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: mailq.pm,v 1.6 2003/09/13 09:16:59 fukachan Exp $ +# $FML: mailq.pm,v 1.7 2003/12/31 03:53:31 fukachan Exp $ # package FML::Command::Admin::mailq; @@ -45,14 +45,14 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 0;} -# Descriptions: change delivery mode from real time to digest. +# Descriptions: show outgoing mail queue. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: update $recipient_map # Return Value: none @@ -64,7 +64,7 @@ sub process } -# Descriptions: open mail queue and list up. +# Descriptions: show outgoing mail queue. # Arguments: OBJ($self) OBJ($curproc) # Side Effects: none # Return Value: none @@ -112,7 +112,7 @@ Ken'ichi Fukamachi =head1 COPYRIGHT -Copyright (C) 2003 Ken'ichi Fukamachi +Copyright (C) 2003,2004 Ken'ichi Fukamachi All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself. diff --git a/fml/lib/FML/Command/Admin/summary.pm b/fml/lib/FML/Command/Admin/summary.pm index 4e5f802d..61582f16 100644 --- a/fml/lib/FML/Command/Admin/summary.pm +++ b/fml/lib/FML/Command/Admin/summary.pm @@ -4,7 +4,7 @@ # All rights reserved. This program is free software; you can # redistribute it and/or modify it under the same terms as Perl itself. # -# $FML: summary.pm,v 1.6 2004/01/01 08:42:22 fukachan Exp $ +# $FML: summary.pm,v 1.7 2004/01/01 08:48:40 fukachan Exp $ # package FML::Command::Admin::summary; @@ -47,14 +47,14 @@ sub new } -# Descriptions: need lock or not +# Descriptions: need lock or not. # Arguments: none # Side Effects: none # Return Value: NUM( 1 or 0) sub need_lock { 1;} -# Descriptions: lock channel +# Descriptions: lock channel. # Arguments: none # Side Effects: none # Return Value: STR @@ -73,7 +73,7 @@ sub process } -# Descriptions: fmlsummary top level dispacher +# Descriptions: fmlsummary top level dispacher. # Arguments: OBJ($self) OBJ($curproc) HASH_REF($command_args) # Side Effects: load FML::Command::command module and execute it. # Return Value: none @@ -82,7 +82,7 @@ sub _summary my ($self, $curproc, $command_args) = @_; my $config = $curproc->config(); my $max_id = $curproc->article_max_id(); - my $options = $command_args->{ options }; + my $options = $command_args->{ options } || []; use FML::Article::Summary; my $summary = new FML::Article::Summary $curproc; @@ -95,6 +95,7 @@ sub _summary $summary->rebuild(1, $max_id); } else { + # XXX-TODO: STDOUT hard coded. ok? my $wh = \*STDOUT; $summary->dump($wh); } |
