summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xbin/weblogs-rotate6
1 files changed, 4 insertions, 2 deletions
diff --git a/bin/weblogs-rotate b/bin/weblogs-rotate
index 874261e..9b46451 100755
--- a/bin/weblogs-rotate
+++ b/bin/weblogs-rotate
@@ -43,8 +43,10 @@ Dir.glob("*").each{ |client|
File.exist?(root_archive_dir+targetname+".bz2")
STDERR.puts("Not moving #{filename}: Target exists.");
else
- puts "Linking #{filename} to statsdir" if $VERBOSE
- File.link( filename , root_forstats_dir+targetname )
+ if filename =~ /access.log$/
+ puts "Linking #{filename} to statsdir" if $VERBOSE
+ File.link( filename , root_forstats_dir+targetname )
+ end
puts "Moving #{filename}" if $VERBOSE
File.rename( filename , root_archive_dir+targetname )
end