From edf9ee67a60fc5bc542ce36090effec420971d41 Mon Sep 17 00:00:00 2001 From: octo Date: Sun, 17 Apr 2005 13:14:57 +0000 Subject: [PATCH] Renamed config to onis.conf Minor changes to onis executable --- contrib/no-chdir/no-chdir.patch | 15 --------------- onis | 20 ++++++++++---------- config => onis.conf | 0 3 files changed, 10 insertions(+), 25 deletions(-) delete mode 100644 contrib/no-chdir/no-chdir.patch rename config => onis.conf (100%) diff --git a/contrib/no-chdir/no-chdir.patch b/contrib/no-chdir/no-chdir.patch deleted file mode 100644 index e55a295..0000000 --- a/contrib/no-chdir/no-chdir.patch +++ /dev/null @@ -1,15 +0,0 @@ -Only in trunk/contrib: no-chdir.patch -diff -ur trunk/onis no-chdir/onis ---- trunk/onis 2005-04-16 00:11:23.000000000 +0200 -+++ no-chdir/onis 2005-04-17 14:52:25.000000000 +0200 -@@ -15,10 +15,6 @@ - - BEGIN - { -- if ($0 =~ m#^(.*)[/\\]#) { chdir ($1); } -- -- unshift (@INC, 'lib'); -- - # 0x0010 Language (make not-translated lines red/yellow) - # 0x0020 Parser (dropped lines) - # 0x0040 Parser (time information) diff --git a/onis b/onis index b0d1bdc..5c2bb2e 100755 --- a/onis +++ b/onis @@ -1,12 +1,12 @@ #!/usr/bin/perl ########################################################################## -# onis 0.7.2 2005-01-21 # +# onis 0.8.0 2005-04-17 # #---=============--------------------------------------------------------# # Language: Perl # # Purpose: Generating statistics # # Input: IRC-Logfiles # # Output: One HTML file # -# Version: 0.7.2 (unstable) # +# Version: 0.8.0 (unstable) # # License: GPL # # Homepage: http://verplant.org/onis/ # # Authors: Florian octo Forster # @@ -49,12 +49,12 @@ if (!$VERSION) } our $FileInfo; -our $PURGE_LOGS = 0; +our $PurgeLogs = 0; print STDERR $/, __FILE__, ': $Id$' if ($::DEBUG); parse_argv (@ARGV); -read_config (get_config ('config') ? get_config ('config') : 'config'); +read_config (get_config ('config') ? get_config ('config') : 'onis.conf'); read_config (scalar get_config ('theme')) if (get_config ('theme')); my $output = get_config ('output'); @@ -138,12 +138,12 @@ if (get_config ('purge_logs')) my $temp = lc (get_config ('purge_logs')); if (($temp eq 'truncate') or ($temp eq 'shorten')) { - $PURGE_LOGS = 1; + $PurgeLogs = 1; } elsif (($temp eq 'delete') or ($temp eq 'remove') or ($temp eq 'del')) { - $PURGE_LOGS = 2; + $PurgeLogs = 2; } } @@ -196,7 +196,7 @@ for (get_config ('input')) } # truncate - if ($PURGE_LOGS == 1) + if ($PurgeLogs == 1) { unless (open ($logfile, '+< ' . $file)) { @@ -213,7 +213,7 @@ for (get_config ('input')) } } - if ($PURGE_LOGS) + if ($PurgeLogs) { unless (flock ($logfile, LOCK_EX)) { @@ -265,11 +265,11 @@ for (get_config ('input')) } } - if ($PURGE_LOGS and (($status == 1) + if ($PurgeLogs and (($status == 1) or ($status == 2) or ($status == 3))) { - if (($PURGE_LOGS > 1) + if (($PurgeLogs > 1) #and (($position + 1) >= $size) ) { diff --git a/config b/onis.conf similarity index 100% rename from config rename to onis.conf -- 2.11.0