Update of /cvsroot/mhonarc/mharc/bin
In directory subversions:/tmp/cvs-serv32449/bin
Modified Files:
read-mail web-archive
Log Message:
* web-archive: Added -mharcdir option to specify location of list
specific resource files. If the file <-mharcdir>/<list-name>.mrc
exists, it will be passed into mhonarc, after common.mrc.
* web-archive: Added support for additional mhonarc options to be
specified in lists.def by defining the MHonArc-Options field.
* web-archive: If the No-Search lists.def field is set to 1 for
a list, then searching will be disabled for the archive: no search
index will be created and the $SEARCH-FORM$ custom resource variable
will be set to the empty string.
* web-archive: Changed some of the default pathname values of some
options. In sum, default pathnames that include "../archive/.."
had the "archive/" component removed.
* web-archive: The following resource variables set have different
names:
$MNAV-CGI$ => $PNAV-CGI$
$CUR-MONTH$ => $CUR-PERIOD$
The old names are still set for backwards compatibility.
* lib/common.mrc.in.dist:
. Removed options in MIMEARGS that could cause security problems.
Users can add options that fit their level of comfort.
. Added definition of $PREV-PERIOD-LABEL$ and $NEXT-PERIOD-LABEL$
which are defined as "Prev Period" and "Next Period",
respectively.
These variables are used for the next/prev period links on the
index pages. Note, these values are a change from the
"Prev Month" and "Next Month".
. The next/prev resource variables for the next/prev period links
have different names:
$NEXT-MONTH-LINK$ => $NEXT-PERIOD-LINK$
$PREV-MONTH-LINK$ => $PREV-PERIOD-LINK$
* read-mail: Added explicit "exit 0" at end of script. This is
to avoid a bogus non-zero exit status of filter-spool finds nothing
to do.
Index: read-mail
===================================================================
RCS file: /cvsroot/mhonarc/mharc/bin/read-mail,v
retrieving revision 1.6
retrieving revision 1.7
diff -C2 -r1.6 -r1.7
*** read-mail 11 Mar 2002 07:55:10 -0000 1.6
--- read-mail 23 May 2002 01:21:53 -0000 1.7
***************
*** 36,37 ****
--- 36,38 ----
bin/filter-spool && bin/web-archive
fi
+ exit 0
Index: web-archive
===================================================================
RCS file: /cvsroot/mhonarc/mharc/bin/web-archive,v
retrieving revision 1.21
retrieving revision 1.22
diff -C2 -r1.21 -r1.22
*** web-archive 15 Mar 2002 06:47:50 -0000 1.21
--- web-archive 23 May 2002 01:21:53 -0000 1.22
***************
*** 94,98 ****
my $HTML_DIR = $opt{'htmldir'} ||
$config->{'HTML_DIR'} ||
! "$HOME/archive/html";
my $HTML_URL = $opt{'htmlurl'} ||
$config->{'HTML_URL'} ||
--- 94,98 ----
my $HTML_DIR = $opt{'htmldir'} ||
$config->{'HTML_DIR'} ||
! "$HOME/html";
my $HTML_URL = $opt{'htmlurl'} ||
$config->{'HTML_URL'} ||
***************
*** 100,104 ****
my $MBOX_DIR = $opt{'mboxdir'} ||
$config->{'MBOX_DIR'} ||
! "$HOME/archive/mbox";
my $MBOX_URL = $opt{'mboxurl'} ||
$config->{'MBOX_URL'} ||
--- 100,104 ----
my $MBOX_DIR = $opt{'mboxdir'} ||
$config->{'MBOX_DIR'} ||
! "$HOME/mbox";
my $MBOX_URL = $opt{'mboxurl'} ||
$config->{'MBOX_URL'} ||
***************
*** 106,110 ****
my $MHA_RC = $opt{'mharc'} ||
$config->{'MHA_RC'} ||
! "$HOME/archive/common.mrc";
my $MHA_MAXSIZE = $opt{'mhamaxsize'} ||
$ENV{'WA_MAXSIZE'} ||
--- 106,113 ----
my $MHA_RC = $opt{'mharc'} ||
$config->{'MHA_RC'} ||
! "$HOME/lib/common.mrc";
! my $MHA_RC_DIR = $opt{'mharcdir'} ||
! $config->{'MHA_RC_DIR'} ||
! "$HOME/lib/mrc";
my $MHA_MAXSIZE = $opt{'mhamaxsize'} ||
$ENV{'WA_MAXSIZE'} ||
***************
*** 122,129 ****
my $MKNMZRC = $opt{'mknmzrc'} ||
$config->{'MKNMZ_RC'} ||
! "$HOME/archive/cgi-bin/mknmzrc";
my $MKNMZTMPLDIR = $opt{'mknmztmpldir'} ||
$config->{'MKNMZ_TMPL_DIR'} ||
! "$HOME/archive/cgi-bin/template",
my $ALL_LISTS_URL = $opt{'alllistsurl'} ||
$config->{'ALL_LISTS_URL'} ||
--- 125,132 ----
my $MKNMZRC = $opt{'mknmzrc'} ||
$config->{'MKNMZ_RC'} ||
! "$HOME/cgi-bin/mknmzrc";
my $MKNMZTMPLDIR = $opt{'mknmztmpldir'} ||
$config->{'MKNMZ_TMPL_DIR'} ||
! "$HOME/cgi-bin/template",
my $ALL_LISTS_URL = $opt{'alllistsurl'} ||
$config->{'ALL_LISTS_URL'} ||
***************
*** 289,295 ****
'-definevar', "LIST-NAME=$list",
'-definevar', "SEARCH-CGI=$SEARCH_CGI",
! '-definevar', "MNAV-CGI=$MNAV_CGI",
'-definevar', "ALL-LISTS-URL=$ALL_LISTS_URL",
);
if ($cvs) {
push(@mhaargs, '-nothread');
--- 292,303 ----
'-definevar', "LIST-NAME=$list",
'-definevar', "SEARCH-CGI=$SEARCH_CGI",
! '-definevar', "PNAV-CGI=$MNAV_CGI",
'-definevar', "ALL-LISTS-URL=$ALL_LISTS_URL",
+
+ '-definevar', "MNAV-CGI=$MNAV_CGI", # backwards compatibility
);
+ if (-e "$MHA_RC_DIR/$list.mrc") {
+ push(@mhaargs, '-rcfile', "$MHA_RC_DIR/$list.mrc");
+ }
if ($cvs) {
push(@mhaargs, '-nothread');
***************
*** 315,318 ****
--- 323,337 ----
}
+ # add any custom options specified in definition file
+ if (defined($listdef->{$list}{'mhonarc-options'})) {
+ require 'shellwords.pl';
+ push(@mhaargs, shellwords($listdef->{$list}{'mhonarc-options'}));
+ }
+
+ # check is searching is disabled
+ if ($listdef->{$list}{'no-search'}) {
+ push(@mhaargs, '-definevar', "SEARCH-FORM=''");
+ }
+
my(@fmhaargs);
@months = ( );
***************
*** 336,340 ****
@mhaargs,
'-outdir', $mondir,
! '-definevar', "CUR-MONTH='$mon'",
);
push(@fmhaargs, $folder) unless $editidx;
--- 355,361 ----
@mhaargs,
'-outdir', $mondir,
! '-definevar', "CUR-PERIOD='$mon'",
!
! '-definevar', "CUR-MONTH='$mon'", # backwards compatibility
);
push(@fmhaargs, $folder) unless $editidx;
***************
*** 565,569 ****
Root directory for html archives.
! If not specified, "C<I<-home>/archive/html>" is used.
=item C<-htmlurl> I<url>
--- 586,590 ----
Root directory for html archives.
! If not specified, "C<I<-home>/html>" is used.
=item C<-htmlurl> I<url>
***************
*** 584,593 ****
Root directory for mbox archives.
! If not specified, "C<I<-home>/archive/mbox>" is used.
=item C<-mharc> I<pathname>
MHonArc resource file for archives.
! If not specified, "C<I<-home>/archive/common.mrc>" is used.
=item C<-mhamaxsize> I<number>
--- 605,623 ----
Root directory for mbox archives.
! If not specified, "C<I<-home>/mbox>" is used.
=item C<-mharc> I<pathname>
MHonArc resource file for archives.
! If not specified, "C<I<-home>/lib/common.mrc>" is used.
!
! =item C<-mharcdir> I<pathname>
!
! Directory containing list-specifc MHonArc resource files. A given
! list archive can have additional resource settings by creating a
! file called C<I<list-name>.mrc> within the directory specified by
! C<-mharcdir>.
!
! If C<-mharcdir> is not specified, "C<I<-home>/lib/mrc>" is used.
=item C<-mhamaxsize> I<number>
***************
*** 609,618 ****
Pathname to Namazu configuration file.
! If not specified, "C<I<-home>/archive/cgi-bin/mknmzrc>" is used.
=item C<-mknmztmpldir> I<pathname>
Pathname to Namazu template directory.
! If not specified, "C<I<-home>/archive/cgi-bin/template>" is used.
=item C<-mnavcgi> I<url>
--- 639,648 ----
Pathname to Namazu configuration file.
! If not specified, "C<I<-home>/cgi-bin/mknmzrc>" is used.
=item C<-mknmztmpldir> I<pathname>
Pathname to Namazu template directory.
! If not specified, "C<I<-home>/cgi-bin/template>" is used.
=item C<-mnavcgi> I<url>
---------------------------------------------------------------------
To sign-off this list, send email to majordomo(_at_)mhonarc(_dot_)org with the
message text UNSUBSCRIBE MHONARC-DEV