changeset 34:1fc5a48a9e7c

2007-09-03 05:13:09 by steve Added optional --lower-case argument.
author steve
date Mon, 03 Sep 2007 05:13:09 +0000
parents a7324ac2c17e
children 62cfade9c5cb
files bin/chronicle
diffstat 1 files changed, 14 insertions(+), 3 deletions(-) [+]
line wrap: on
line diff
--- a/bin/chronicle	Mon Sep 03 05:00:43 2007 +0000
+++ b/bin/chronicle	Mon Sep 03 05:13:09 2007 +0000
@@ -54,7 +54,7 @@
  --
  http://www.steve.org.uk/
 
- $Id: chronicle,v 1.13 2007-09-03 05:00:43 steve Exp $
+ $Id: chronicle,v 1.14 2007-09-03 05:13:09 steve Exp $
 
 =cut
 
@@ -319,6 +319,7 @@
                "no-tags",      \$CONFIG{'no-tags'},
                "no-cache",     \$CONFIG{'no-cache'},
                "no-archive",   \$CONFIG{'no-archive'},
+               "lower-case",   \$CONFIG{'lower-case'},
 
                # prefix
                "url-prefix=s", \$CONFIG{'url_prefix'},
@@ -334,7 +335,7 @@
 
     if ( $VERSION )
     {
-        my $REVISION      = '$Revision: 1.13 $';
+        my $REVISION      = '$Revision: 1.14 $';
         if ( $REVISION =~ /1.([0-9.]+) / )
         {
             $REVISION = $1;
@@ -526,7 +527,7 @@
         push( @$results,
             { tag   => $key,
               count => $count,
-              size  => $size} );
+              size  => $size } );
     }
     return $results;
 
@@ -1065,11 +1066,15 @@
     {
         $basename=$2;
     }
+
     #
     #  Read the entry
     #
     my $static = readBlogEntry( $filename );
 
+    #
+    #  Get the pieces of information.
+    #
     my $title = $static->{'title'} || $basename;
     my $tags  = $static->{'tags'};
     my $body  = $static->{'body'};
@@ -1302,6 +1307,12 @@
 
     my $suffix = $CONFIG{'suffix'} ||".html";
     $file .= $suffix;
+
+    #
+    #  Lower case?
+    #
+    $file = lc($file) if ( $CONFIG{'lower-case'} );
+
     return( $file );
 
 }