Mercurial > hg > chronicle
changeset 241:a534e06653dd
Patch from MJ Ray - allow entries with a Published: date in the future
to be silently skipped over
author | Steve Kemp <steve@steve.org.uk> |
---|---|
date | Fri, 16 May 2008 17:39:25 +0100 |
parents | e1d0a8576342 |
children | af29da68fa82 |
files | bin/chronicle |
diffstat | 1 files changed, 17 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/bin/chronicle Fri May 16 17:37:07 2008 +0100 +++ b/bin/chronicle Fri May 16 17:39:25 2008 +0100 @@ -612,7 +612,9 @@ # Read the entry and store all the data away as a # hash element keyed upon the (unique) filename. # - $results{ $file } = readBlogEntry($file); + my $result = readBlogEntry($file); + $results{ $file } = $result if ( $result ); + } # @@ -1533,6 +1535,20 @@ close(ENTRY); # + # MJR - embargo the entry until the publish if it + # is in the future. + # + # Steve prefers using chronicle-spooler, but I want + # uploaded files to stay where I put them, else I get + # my local copy confused. + # + if (($publish ne "") && (str2time($publish) > time())) + { + return 0; + } + + + # # Determine the input format to use. # my $format = lc( $CONFIG{ 'format' } );