Commit 2f59a050 authored by Mike Hibler's avatar Mike Hibler

Add removal of BSD packages if they exist

parent d6f33953
......@@ -10,6 +10,11 @@ use English;
#
# Remove all traces of elvin from a client
#
my @BSDPKGS = (
'elvind-4.0.3',
'libelvin-4.0.3_2'
);
my @BSDFILES = (
'/usr/local/etc/rc.d/elvind.sh',
'/usr/local/bin/elvin-config',
......@@ -51,6 +56,12 @@ if ($isbsd) {
system("sed -i '' -e '/elvind/d' /etc/syslog.conf");
# remove any packages?
foreach my $pkg (@BSDPKGS) {
if (!system("pkg_info -e $pkg")) {
print "removing $pkg package...\n";
system("pkg_delete -f $pkg");
}
}
# remove known files
my @list = `ls -d @BSDFILES 2>/dev/null`;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment