From a364570173a20cdad499631f572818839289dfe5 Mon Sep 17 00:00:00 2001 From: Guillaume Rousse Date: Thu, 6 Sep 2007 12:24:52 +0000 Subject: add markers for easier removal --- add-syslog | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'add-syslog') diff --git a/add-syslog b/add-syslog index a8564b2..092d50b 100755 --- a/add-syslog +++ b/add-syslog @@ -136,8 +136,9 @@ sub add_sysklogd_entry { # append entry open(my $out, '>>', '/etc/syslog.conf') or die "Can't open /etc/syslog.conf for appending: $!"; - print $out "# Automatically added by $package installation\n"; + print $out "# BEGIN: Automatically added by $package installation\n"; print $out $selector . ("\t" x $tabs) . '-' . $dest . "\n"; + print $out "# END\n"; close($out); # relaunch syslog @@ -205,7 +206,7 @@ sub add_syslogng_entry { open(my $out, '>>', '/etc/syslog-ng.conf') or die "Can't open /etc/syslog-ng.conf for appending: $!"; - print $out "# Automatically added by $package installation\n"; + print $out "# BEGIN: Automatically added by $package installation\n"; if (!$source_id) { $source_id = 's_' . $package; print $out "source $source_id { unix-stream('$source'); };\n"; @@ -226,6 +227,7 @@ sub add_syslogng_entry { " filter($facility_id);" . " filter($level_id);" . " destination($destination_id); };\n"; + print $out "# END\n"; close($out); # relaunch syslog-ng -- cgit v1.2.1