[Ftnpl-cvs] SF.net SVN: ftnpl:[624] trunk/scripts/BBBS/bconfhtm
Brought to you by:
jame
|
From: <ja...@us...> - 2011-08-13 16:03:52
|
Revision: 624
http://ftnpl.svn.sourceforge.net/ftnpl/?rev=624&view=rev
Author: jame
Date: 2011-08-13 16:03:45 +0000 (Sat, 13 Aug 2011)
Log Message:
-----------
bconf2html.pl v0.3
* develop:
Changes file for version v0.3
doc/TODO as of 13 August 2011.
Cleanup of whitespace in some files.
Explicitly use Carp.
Correct the file open line in bin/bconf2html.pl
Rename bin/bconfhtm.pl as bin/bconf2html.pl
Fix declaration of option variables in bconfhtm.pl
Rename ignore.txt as .gitignore
General cleanup of bin/bconfhtm, referencing Perl::Tidy.
List bin/bconfhtm.sh in MANIFEST.
Update README, especially regarding GitHub.
List bconfhtm.pl & bcnfhtml.tpl in MANIFEST.
Reorganize bconfhtm source directory.
Modified Paths:
--------------
trunk/scripts/BBBS/bconfhtm/README
trunk/scripts/BBBS/bconfhtm/doc/TODO
Added Paths:
-----------
trunk/scripts/BBBS/bconfhtm/.gitignore
trunk/scripts/BBBS/bconfhtm/Changes
trunk/scripts/BBBS/bconfhtm/MANIFEST
trunk/scripts/BBBS/bconfhtm/Makefile.PL
trunk/scripts/BBBS/bconfhtm/bin/
trunk/scripts/BBBS/bconfhtm/bin/bconf2html.pl
trunk/scripts/BBBS/bconfhtm/bin/bconfhtm.sh
trunk/scripts/BBBS/bconfhtm/doc/FILE_ID.DIZ
trunk/scripts/BBBS/bconfhtm/doc/bcnfhtml.tpl
Removed Paths:
-------------
trunk/scripts/BBBS/bconfhtm/FILE_ID.DIZ
trunk/scripts/BBBS/bconfhtm/bcnfhtml.tpl
trunk/scripts/BBBS/bconfhtm/bconfhtm.pl
trunk/scripts/BBBS/bconfhtm/bconfhtm.sh
trunk/scripts/BBBS/bconfhtm/doc/Changes
Added: trunk/scripts/BBBS/bconfhtm/.gitignore
===================================================================
--- trunk/scripts/BBBS/bconfhtm/.gitignore (rev 0)
+++ trunk/scripts/BBBS/bconfhtm/.gitignore 2011-08-13 16:03:45 UTC (rev 624)
@@ -0,0 +1,12 @@
+blib*
+Makefile
+Makefile.old
+Build
+Build.bat
+_build*
+pm_to_blib*
+*.tar.gz
+.lwpcookies
+cover_db
+pod2htm*.tmp
+BCONFHTM-*
Added: trunk/scripts/BBBS/bconfhtm/Changes
===================================================================
--- trunk/scripts/BBBS/bconfhtm/Changes (rev 0)
+++ trunk/scripts/BBBS/bconfhtm/Changes 2011-08-13 16:03:45 UTC (rev 624)
@@ -0,0 +1,37 @@
+Changes
+--------
+
+13 Aug 11
+ - Released as v0.3
+ - Cleanup of whitespace in some files.
+ - Explicitly 'use Carp' in bconf2html.pl
+ - Rename bin/bconfhtm.pl as bin/bconf2html.pl
+ - Correct the 'file open' line in bin/bconf2html.pl
+ - Fix declaration of option variables in bconf2html.pl
+
+ 7 Jul 11
+ - Reorganize the bconfhtm source directory.
+ - Edit line 6 of bcnfhtml.tpl to correct spelling, etc.
+ - Use example.org for domain in example bcnfhtml.tpl file.
+ - Update the README file about bconfhtm being at GitHub.
+ - General cleanup of bconfhtm script, referencing Perl::Tidy.
+
+29 Jun 11
+ - Bump bconfhtm version to v0.3
+ - Update bconfhtm copyright years to include the year 2011.
+
+31 Jul 10
+ - Released as v0.2
+ - README: Add bconfhtm usage and support information. Correct
+ one of the contact email addresses. Minor edits.
+ - Reword & edit Help subroutine in bconfhtm.pl.
+
+28 Jul 10
+ - Bump bconfhtm version to v0.2
+ - Update bconfhtm copyright years to include the year 2010.
+ - Correct declaration of option variables in bconfhtm.pl.
+
+26 Jun 06
+ - Released as v0.1
+ - Corrections & additions to meta's in bcnfhtml.tpl template file.
+ - Initial import of bconfhtm.pl into cvs at ftnpl.sourceforge.net.
Deleted: trunk/scripts/BBBS/bconfhtm/FILE_ID.DIZ
===================================================================
--- trunk/scripts/BBBS/bconfhtm/FILE_ID.DIZ 2011-08-13 16:03:26 UTC (rev 623)
+++ trunk/scripts/BBBS/bconfhtm/FILE_ID.DIZ 2011-08-13 16:03:45 UTC (rev 624)
@@ -1,7 +0,0 @@
-bconfhtm.pl v0.3
-Perl script that creates an html page
-from a file resulting from the BBBS
-command 'bbbs bconf'. Requires the
-HTML::Template modulue. See README
-for more information.
-
Added: trunk/scripts/BBBS/bconfhtm/MANIFEST
===================================================================
--- trunk/scripts/BBBS/bconfhtm/MANIFEST (rev 0)
+++ trunk/scripts/BBBS/bconfhtm/MANIFEST 2011-08-13 16:03:45 UTC (rev 624)
@@ -0,0 +1,8 @@
+Changes
+MANIFEST
+Makefile.PL
+README
+bin/bconfhtm.sh
+bin/bconf2html.pl
+doc/bcnfhtml.tpl
+doc/TODO
Added: trunk/scripts/BBBS/bconfhtm/Makefile.PL
===================================================================
--- trunk/scripts/BBBS/bconfhtm/Makefile.PL (rev 0)
+++ trunk/scripts/BBBS/bconfhtm/Makefile.PL 2011-08-13 16:03:45 UTC (rev 624)
@@ -0,0 +1,23 @@
+use strict;
+use warnings;
+use ExtUtils::MakeMaker;
+
+WriteMakefile(
+ NAME => 'bconfhtm',
+ AUTHOR => q{Robert James Clay <ja...@ro...>},
+ VERSION_FROM => 'bin/bconf2html.pl',
+ ABSTRACT => 'Create a BBBS Conference Statistics HTML page for a BBBS system.',
+ ($ExtUtils::MakeMaker::VERSION >= 6.3002
+ ? ('LICENSE'=> 'perl')
+ : ()),
+ EXE_FILES => [ qw( bin/bconf2html.pl ) ],
+ PL_FILES => {},
+ PREREQ_PM => {
+ 'Readonly' => 0,
+ 'Getopt::Std' => 0,
+ 'File::Slurp' => 0,
+ 'HTML::Template' => 0,
+ },
+ dist => { COMPRESS => 'gzip -9f', SUFFIX => 'gz', },
+ clean => { FILES => 'bconfhtm-*' },
+);
Modified: trunk/scripts/BBBS/bconfhtm/README
===================================================================
--- trunk/scripts/BBBS/bconfhtm/README 2011-08-13 16:03:26 UTC (rev 623)
+++ trunk/scripts/BBBS/bconfhtm/README 2011-08-13 16:03:45 UTC (rev 624)
@@ -1,13 +1,14 @@
-bconfhtm.pl v0.3
+bconf2html.pl
Copyright (c) 2006-2011 Robert James Clay
All Rights Reserved. This is free software; you can redistribute
it and/or modify it under the same terms as Perl itself.
-Perl script that creates an html page from a file resulting from the BBBS command
-'bbbs bconf' and an HTML template file. Requires the HTML::Template module.
+Perl script that creates an html page from a file resulting from the BBBS
+command 'bbbs bconf' and an HTML template file. Requires the HTML::Template
+module.
-Usage: bconfhtm.pl [-t Template] [-o HTMLDir] [-s StatsFile] [-f HTMLFileName] [-l LogFile] [-x] [-h]
+Usage: bconf2html.pl [-t Template] [-o HTMLDir] [-s StatsFile] [-f HTMLFileName] [-l LogFile] [-x] [-h]
Options:
-t HTML page template file. Defaults to /opt/bbbs/work/bcnfhtml.tpl.
@@ -18,50 +19,60 @@
-x Debug Mode
-h This Help
-It is hosted at the FTN for Perl project at Sourceforge and the current code for it can be browsed at:
-http://ftnpl.svn.sourceforge.net/viewvc/ftnpl/trunk/scripts/BBBS/bconfhtm/
+It is hosted at the FTN for Perl project at Sourceforge and the original code
+for it can be browsed for in the SVN repository at:
+ http://ftnpl.svn.sourceforge.net/viewvc/ftnpl/trunk/scripts/BBBS/bconfhtm/
+The current code for it can be found at the GIT repository at the bbbsdeb
+project at GitHub:
+http://github.com/bbbsdeb/bconfhtm.
-Archives of it can be found in the Project file downloads section. They can also be found on any FTN
-system that carries the BBBSUTIL File Echo, which is distributed via the Filegate (www.filegate.net).
+Archives of it can be found in the Project file downloads section. They can
+also be found on any FTN system that carries the BBBSUTIL File Echo, which is
+distributed via the Filegate (www.filegate.net). Or they can be obtained from
+the downloads section of the bconfhtm repository at GitHub.com/bbbsdeb/bconfhtm.
The ftnpl-user or ftnpl-develop mailing lists are available from the project site;
however, the FTN echo BBBS.ENGLISH is the preferred avenue for support.
-
+
============================================================
Files
----------------
-bconfhtm.pl Perl script that creates an html page from a file resulting
- from the BBBS command 'bbbs bconf'.
+bconf2html.pl Perl script that creates an html page from a file resulting
+ from the BBBS command 'bbbs bconf'.
-bcnfhtml.tpl Example HTML Template file for the page to be created.
+bcnfhtml.tpl Example HTML Template file for the page to be created.
-bconfhtm.sh Example shell script. Uses bconfhtm.pl with parameters to
- create an html page from a file resulting from the BBBS
- command 'bbbs bconf'. The variables should be modified as
- neccessary for your local setup.
+bconfhtm.sh Example shell script. Uses bconf2html.pl with parameters to
+ create an html page from a file resulting from the BBBS
+ command 'bbbs bconf'. The variables should be modified as
+ neccessary for your local setup.
-doc/TODO What needs to be, or is being, worked on
-doc/Changes Changes file
+doc/TODO What needs to be, or is being, worked on
+Changes Changes file
README This file
-FILE_ID.DIZ Description of archive.
+FILE_ID.DIZ Description of archive.
============================================================
Installation
----------------
+
1) Unzip the archive to a temporary directory
+ perl Makefile.PL
+ make
+ make install
2) Move the bcnfthml.tpl to the /opt/bbbs/work directory
-3) Move the bconfhtm.pl & bconfhtm.sh /opt/bbbs/scripts
+3) Move the bconf2html.pl & bconfhtm.sh /opt/bbbs/scripts
4) Make changes as neccessary to the template file
5) Make changes as neccesary to the bconfhtm.sh script
6) Add the running of the bconfhtm.sh script as a daily
event to the BBBS crontab or to another daily script
-
+
==================================
Robert J. Clay, 1:120/546@fidonet
ja...@us..., ja...@ro...
http://ftnpl.sourceforge.net
-
\ No newline at end of file
+http://github.com/bbbsdeb/bconfhtm
Deleted: trunk/scripts/BBBS/bconfhtm/bcnfhtml.tpl
===================================================================
--- trunk/scripts/BBBS/bconfhtm/bcnfhtml.tpl 2011-08-13 16:03:26 UTC (rev 623)
+++ trunk/scripts/BBBS/bconfhtm/bcnfhtml.tpl 2011-08-13 16:03:45 UTC (rev 624)
@@ -1,29 +0,0 @@
-<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
-<html>
- <head>
- <meta http-equiv="content-type" content="charset=UTF-8" />
- <meta name="Author" content="Robert James Clay" />
- <meta name="Keywords" content="Fidonet, FTN, Statistics" />
- <meta name="Generator" content="bconfhtm.pl v0.3" />
- <meta HTTP-EQUIV="EXPIRES" content="<TMPL_VAR NAME="PAGEEXPIRES">" />
-
- <link rel="stylesheet" type="text/css" href="./bbbs.css" />
- <title>BBBS Conference Stats </title>
-
- </head>
-
- <body>
-
- <h1>example.org</h1>
- <h2>BBBS Conference Statistics</h2>
-
- <pre>
-<TMPL_VAR NAME="BCONFSTATS">
- </pre>
-
- <hr>
-
- • <strong>Updated »</strong> <TMPL_VAR NAME="HOURS">:<TMPL_VAR NAME="MINS"> <TMPL_VAR NAME="MON">/<TMPL_VAR NAME="DAY">/<TMPL_VAR NAME="YEAR">
-
- </body>
-</html>
Deleted: trunk/scripts/BBBS/bconfhtm/bconfhtm.pl
===================================================================
--- trunk/scripts/BBBS/bconfhtm/bconfhtm.pl 2011-08-13 16:03:26 UTC (rev 623)
+++ trunk/scripts/BBBS/bconfhtm/bconfhtm.pl 2011-08-13 16:03:45 UTC (rev 624)
@@ -1,141 +0,0 @@
-#!/usr/bin/perl
-# bconfhtm.pl Copyright (c) 2006-2011 Robert James Clay
-# Used to creat a BBBS Conference Statistics HTML page for a BBBS system.
-# All Rights Reserved. This is free software; you can redistribute
-# it and/or modify it under the same terms as Perl itself.
-
-use warnings;
-use strict;
-
-my $Version = "0.3";
-
-use File::Slurp;
-use HTML::Template;
-use Getopt::Std;
-
-our ($opt_t $opt_o $opt_s $opt_f $opt_l $opt_x $opt_h);
-my ($STATFILE, $TEMPLATE, $WORKDIR, $HTMLFILE, $expires, $expiry, $logfile, $DEBUG);
-
-
-getopts('t:o:f:s:l:xh');
-
-&ParseCommandLine();
-
-# set BBBS base directory
-my $BBBSDIR = "/opt/bbbs";
-
-#get current time as timestamp
-my $timestamp = time();
-# set page expiration time
-$expiry = 86400; # 86400 seconds, equals 1 day
-
-$expires = gmtime($timestamp + $expiry);
-
-# get local time as string
-my ($sec, $min, $hour, $day, $mon, $year, $wday, $yday, $isdst) = localtime($timestamp);
-
-# open & read the file containing the result of the command 'bbbs bconf', which is put in $bconfstats
-my $bconfstats = read_file("$STATFILE");
-
-# open the html template
-my $template = HTML::Template->new(filename => "$TEMPLATE");
-
-# fill in the template parameters
-$template->param(PAGEEXPIRES => $expires);
-
-$template->param(BCONFSTATS => $bconfstats);
-
-$template->param(DAY => $day);
-$template->param(MON => ($mon + 1));
-$template->param(YEAR => ($year + 1900));
-$template->param(HOURS => $hour);
-$template->param(MINS => $min);
-
-# create new version of conference stats html page
-my $newpage="$WORKDIR/$HTMLFILE";
-# open filehandle FH for write
-open(FH, "> $newpage") || die $!;
-
-# use the function to send the new contents to the new version of the file
-$template->output(print_to => *FH);
-
-# close the filehandle
-close(FH);
-
-exit(0);
-
-################################################
-## Subroutines
-##
-############################################
-# ParseCommandLine
-############################################
-sub ParseCommandLine {
-
- if ($opt_h) {
- &DisplayHelp();
- exit(1);
- }
-
- if ($opt_x) {
- $DEBUG = $opt_x; # set debug flag
- undef $opt_x;
- print "\nDebug flag is set ...\n";
- } else {
- $DEBUG = 0;
- }
-
- if ($opt_t) {
- $TEMPLATE=$opt_t; # this needs to be the filename & path
- undef $opt_t;
- } else {
- $TEMPLATE="/opt/bbbs/work/bcnfhtml.tpl"; # default template file
- }
-
- if ($opt_o) {
- $WORKDIR=$opt_o; # this needs to be the filename & path
- undef $opt_o;
- } else {
- $WORKDIR="/opt/bbbs/work"; # default working dir
- }
-
- if ($opt_s) {
- $STATFILE=$opt_s; # this needs to be the filename & path
- undef $opt_s;
- } else {
- $STATFILE="/opt/bbbs/work/bconf.txt"; # default stats file
- }
-
- if ($opt_f) {
- $HTMLFILE=$opt_f; # this needs to be the filename & path
- undef $opt_f;
- } else {
- $HTMLFILE="/opt/bbbs/work/bcnfstat.htm"; # default stats file
- }
-
- if ($opt_l) {
- $logfile=$opt_l; # this needs to be the filename & path for a logfile
- undef $opt_l;
- } else {
- my $logfile="/opt/bbbs/logs/wwwadm.log"; # default log file
- }
-
-}
-############################################
-# Help
-############################################
-sub DisplayHelp {
- print "\nUsage: bconfhtm.pl [-t Template] [-o HTMLDir] [-s StatsFile] / \n";
- print " [-f HTMLFileName] [-l LogFile] [-x] [-h]\n\n";
- print " -t HTML page template file; defaults to /opt/bbbs/work/bcnfhtml.tpl. \n";
- print " -o Directory where the resulting HTML file should be put.\n";
- print " Defaults to /opt/bbbs/work.\n";
- print " -s Path & filename for Stats file generated by the 'BBBS BCONF' \n";
- print " command. Defaults to /opt/bbbs/work/bconf.txt.\n";
- print " -f Filename for HTML file being created. \n";
- print " -l Path & filename of logfile. Defaults to /opt/bbbs/logs/wwwadm.log.\n";
- print " -x Debug Mode\n";
- print " -h This Help\n";
- print "\n";
-}
-
Deleted: trunk/scripts/BBBS/bconfhtm/bconfhtm.sh
===================================================================
--- trunk/scripts/BBBS/bconfhtm/bconfhtm.sh 2011-08-13 16:03:26 UTC (rev 623)
+++ trunk/scripts/BBBS/bconfhtm/bconfhtm.sh 2011-08-13 16:03:45 UTC (rev 624)
@@ -1,25 +0,0 @@
-#!/bin/sh
-# bconfhtm.sh - v0.3
-#
-BBBSDIR=/opt/bbbs
-SCRIPTS=$BBBSDIR/scripts
-WORKDIR=$BBBSDIR/work
-TEMPLATE=$WORKDIR/bcnfhtml.tpl
-HTMLDIR=$BBBSDIR/htdocs
-STATSFILE=$WORKDIR/bcnfstat.txt
-HTMLFILE=bcnfstat.htm
-
-cd $BBBSDIR
-
-# create Conference Statistics file
-$BBBSDIR/bbbs bconf > $STATSFILE
-
-# bconfhtm.pl -t Template -o HTMLDir -s StatsFile [-f HTMLFile] [-l LogFile] [-x] [-h]
-$SCRIPTS/bconfhtm.pl -t $TEMPLATE -o $WORKDIR -s $STATSFILE -f $HTMLFILE
-
-# put new version of file online
-cp $WORKDIR/$HTMLFILE $HTMLDIR/$HTMLFILE
-
-# delete working copy
-rm $WORKDIR/$HTMLFILE
-
Copied: trunk/scripts/BBBS/bconfhtm/bin/bconf2html.pl (from rev 623, trunk/scripts/BBBS/bconfhtm/bconfhtm.pl)
===================================================================
--- trunk/scripts/BBBS/bconfhtm/bin/bconf2html.pl (rev 0)
+++ trunk/scripts/BBBS/bconfhtm/bin/bconf2html.pl 2011-08-13 16:03:45 UTC (rev 624)
@@ -0,0 +1,160 @@
+#!/usr/bin/perl
+# bconf2html.pl Copyright (c) 2006-2011 Robert James Clay
+# Used to create a BBBS Conference Statistics HTML page for a BBBS system.
+# All Rights Reserved. This is free software; you can redistribute
+# it and/or modify it under the same terms as Perl itself.
+
+use warnings;
+use strict;
+
+our $VERSION = '0.3';
+
+use File::Slurp;
+use HTML::Template;
+use Getopt::Std;
+use Carp;
+
+our ($opt_t, $opt_o, $opt_s, $opt_f, $opt_l, $opt_x, $opt_h);
+my ($STATFILE, $TEMPLATE, $WORKDIR, $HTMLFILE, $expires, $expiry, $logfile, $DEBUG);
+
+use Readonly;
+Readonly my $DAYOFSECS => 86_400;
+Readonly my $NINETEENTH => 1900;
+
+getopts('t:o:f:s:l:xh');
+
+parse_command_line();
+
+# set BBBS base directory
+my $BBBSDIR = '/opt/bbbs';
+
+#get current time as timestamp
+my $timestamp = time();
+# set page expiration time
+# 86,400 seconds, equals 1 day
+$expiry = $DAYOFSECS;
+
+$expires = gmtime($timestamp + $expiry);
+
+# get local time as string
+my ($sec, $min, $hour, $day, $mon, $year, $wday, $yday, $isdst) = localtime($timestamp);
+
+# open & read the file containing the result of the command 'bbbs bconf', which is put in $bconfstats
+my $bconfstats = read_file("$STATFILE");
+
+# open the html template
+my $template = HTML::Template->new(filename => "$TEMPLATE");
+
+# fill in the template parameters
+$template->param(PAGEEXPIRES => $expires);
+
+$template->param(BCONFSTATS => $bconfstats);
+
+$template->param(DAY => $day);
+$template->param(MON => ($mon + 1));
+$template->param(YEAR => ($year + $NINETEENTH));
+$template->param(HOURS => $hour);
+$template->param(MINS => $min);
+
+# create new version of conference stats html page
+my $newpage="$WORKDIR/$HTMLFILE";
+# open filehandle FH for write
+open my $fh, q{>}, $newpage || croak $!;
+
+# use the function to send the new contents to the new version of the file
+$template->output(print_to => *$fh);
+
+# close the filehandle
+close($fh) or croak "Unable to close: $!";
+
+exit 0;
+
+################################################
+## Subroutines
+##
+############################################
+# parse_command_line
+############################################
+sub parse_command_line {
+
+ if ($opt_h) {
+ display_help();
+ exit 1;
+ }
+
+ if ($opt_x) {
+ # set debug flag
+ $DEBUG = $opt_x;
+ undef $opt_x;
+ print "\nDebug flag is set ...\n";
+ } else {
+ $DEBUG = 0;
+ }
+
+ if ($opt_t) {
+ $TEMPLATE=$opt_t; # this needs to be the filename & path
+ undef $opt_t;
+ } else {
+ # default template file
+ $TEMPLATE='/opt/bbbs/work/bcnfhtml.tpl';
+ }
+
+ if ($opt_o) {
+ # this needs to be the filename & path
+ $WORKDIR=$opt_o;
+ undef $opt_o;
+ } else {
+ # default working directory
+ $WORKDIR='/opt/bbbs/work';
+ }
+
+ if ($opt_s) {
+ # this needs to be the filename & path
+ $STATFILE=$opt_s;
+ undef $opt_s;
+ } else {
+ # default stats file
+ $STATFILE='/opt/bbbs/work/bconf.txt';
+ }
+
+ if ($opt_f) {
+ # this needs to be the filename & path
+ $HTMLFILE=$opt_f;
+ undef $opt_f;
+ } else {
+ # default stats file
+ $HTMLFILE='/opt/bbbs/work/bcnfstat.htm';
+ }
+
+ if ($opt_l) {
+ # this needs to be the filename & path for a logfile
+ $logfile=$opt_l;
+ undef $opt_l;
+ } else {
+ # default log file
+ $logfile='/opt/bbbs/logs/wwwadm.log';
+ }
+
+ return();
+
+}
+############################################
+# Help
+############################################
+sub display_help {
+ print "\nUsage: bconf2html.pl [-t Template] [-o HTMLDir] [-s StatsFile] / \n";
+ print " [-f HTMLFileName] [-l LogFile] [-x] [-h]\n\n";
+ print " -t HTML page template file; defaults to /opt/bbbs/work/bcnfhtml.tpl. \n";
+ print " -o Directory where the resulting HTML file should be put.\n";
+ print " Defaults to /opt/bbbs/work.\n";
+ print " -s Path & filename for Stats file generated by the 'BBBS BCONF' \n";
+ print " command. Defaults to /opt/bbbs/work/bconf.txt.\n";
+ print " -f Filename for HTML file being created. \n";
+ print " -l Path & filename of logfile. Defaults to /opt/bbbs/logs/wwwadm.log.\n";
+ print " -x Debug Mode\n";
+ print " -h This Help\n";
+ print "\n";
+
+ return();
+}
+
Copied: trunk/scripts/BBBS/bconfhtm/bin/bconfhtm.sh (from rev 623, trunk/scripts/BBBS/bconfhtm/bconfhtm.sh)
===================================================================
--- trunk/scripts/BBBS/bconfhtm/bin/bconfhtm.sh (rev 0)
+++ trunk/scripts/BBBS/bconfhtm/bin/bconfhtm.sh 2011-08-13 16:03:45 UTC (rev 624)
@@ -0,0 +1,25 @@
+#!/bin/sh
+# bconfhtm.sh - v0.3
+#
+BBBSDIR=/opt/bbbs
+SCRIPTS=$BBBSDIR/scripts
+WORKDIR=$BBBSDIR/work
+TEMPLATE=$WORKDIR/bcnfhtml.tpl
+HTMLDIR=$BBBSDIR/htdocs
+STATSFILE=$WORKDIR/bcnfstat.txt
+HTMLFILE=bcnfstat.htm
+
+cd $BBBSDIR
+
+# create Conference Statistics file
+$BBBSDIR/bbbs bconf > $STATSFILE
+
+# bconf2html.pl -t Template -o HTMLDir -s StatsFile [-f HTMLFile] [-l LogFile] [-x] [-h]
+$SCRIPTS/bconf2html.pl -t $TEMPLATE -o $WORKDIR -s $STATSFILE -f $HTMLFILE
+
+# put new version of file online
+cp $WORKDIR/$HTMLFILE $HTMLDIR/$HTMLFILE
+
+# delete working copy
+rm $WORKDIR/$HTMLFILE
+
Deleted: trunk/scripts/BBBS/bconfhtm/doc/Changes
===================================================================
--- trunk/scripts/BBBS/bconfhtm/doc/Changes 2011-08-13 16:03:26 UTC (rev 623)
+++ trunk/scripts/BBBS/bconfhtm/doc/Changes 2011-08-13 16:03:45 UTC (rev 624)
@@ -1,23 +0,0 @@
-Changes
---------
-
-29 Jun 11
- - Bump bconfhtm version to v0.3
- - Update bconfhtm copyright years to include the year 2011.
-
-31 Jul 10
- - Released as v0.2
- - README: Add bconfhtm usage and support information. Correct
- one of the contact email addresses. Minor edits.
- - Reword & edit Help subroutine in bconfhtm.pl.
-
-28 Jul 10
- - Bump bconfhtm version to v0.2
- - Update bconfhtm copyright years to include the year 2010.
- _ Correct declaration of option variables in bconfhtm.pl.
-
-26 Jun 06
- - Released as v0.1
- - Corrections & additions to meta's in bcnfhtml.tpl template file.
- - Initial import of bconfhtm.pl into cvs at ftnpl.sourceforge.net.
-
\ No newline at end of file
Copied: trunk/scripts/BBBS/bconfhtm/doc/FILE_ID.DIZ (from rev 623, trunk/scripts/BBBS/bconfhtm/FILE_ID.DIZ)
===================================================================
--- trunk/scripts/BBBS/bconfhtm/doc/FILE_ID.DIZ (rev 0)
+++ trunk/scripts/BBBS/bconfhtm/doc/FILE_ID.DIZ 2011-08-13 16:03:45 UTC (rev 624)
@@ -0,0 +1,7 @@
+bconf2html.pl v0.x
+Perl script that creates an html page
+from a file resulting from the BBBS
+command 'bbbs bconf'. Requires the
+HTML::Template modulue. See README
+for more information.
+
Modified: trunk/scripts/BBBS/bconfhtm/doc/TODO
===================================================================
--- trunk/scripts/BBBS/bconfhtm/doc/TODO 2011-08-13 16:03:26 UTC (rev 623)
+++ trunk/scripts/BBBS/bconfhtm/doc/TODO 2011-08-13 16:03:45 UTC (rev 624)
@@ -1,5 +1,18 @@
-To do: bconfhtm 7/31/10
+To Do: bconfhtm 8/13/11
+bconf2html.pl
+
+ - Change to using a simple config file, which points to the directories and
+ files needed by the script.
+
+ - Move example shell script into POD documentation in bconfhtm script?
+
+ - Have configurable/optional expiry times, instead of just the default 1 day?
+
+ - Expires meta: per RFC 2068, HTTP timestamps should be in GMT and
+ in RFC 1123 format. (Mon, 22 Jul 2002 11:12:01 GMT) -> check & fix
+
bcnfhtml.tpl
+
- Expires meta: per RFC 2068, HTTP timestamps should be in GMT and
- in RFC 1123 format. (Mon, 22 Jul 2002 11:12:01 GMT) -> check & fix
\ No newline at end of file
+ in RFC 1123 format. (Mon, 22 Jul 2002 11:12:01 GMT) -> check & fix
Copied: trunk/scripts/BBBS/bconfhtm/doc/bcnfhtml.tpl (from rev 623, trunk/scripts/BBBS/bconfhtm/bcnfhtml.tpl)
===================================================================
--- trunk/scripts/BBBS/bconfhtm/doc/bcnfhtml.tpl (rev 0)
+++ trunk/scripts/BBBS/bconfhtm/doc/bcnfhtml.tpl 2011-08-13 16:03:45 UTC (rev 624)
@@ -0,0 +1,29 @@
+<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN">
+<html>
+ <head>
+ <meta http-equiv="content-type" content="charset=UTF-8" />
+ <meta name="Author" content="Robert James Clay" />
+ <meta name="Keywords" content="Fidonet, FTN, Statistics" />
+ <meta name="Generator" content="bconf2html.pl v0.3" />
+ <meta HTTP-EQUIV="EXPIRES" content="<TMPL_VAR NAME="PAGEEXPIRES">" />
+
+ <link rel="stylesheet" type="text/css" href="./bbbs.css" />
+ <title>BBBS Conference Stats </title>
+
+ </head>
+
+ <body>
+
+ <h1>example.org</h1>
+ <h2>BBBS Conference Statistics</h2>
+
+ <pre>
+<TMPL_VAR NAME="BCONFSTATS">
+ </pre>
+
+ <hr>
+
+ • <strong>Updated »</strong> <TMPL_VAR NAME="HOURS">:<TMPL_VAR NAME="MINS"> <TMPL_VAR NAME="MON">/<TMPL_VAR NAME="DAY">/<TMPL_VAR NAME="YEAR">
+
+ </body>
+</html>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|