Remove renamed plugin Mute
This commit is contained in:
parent
c7a8a3933e
commit
e564470490
1 changed files with 9 additions and 0 deletions
|
@ -1,6 +1,8 @@
|
|||
import logging
|
||||
import os
|
||||
import sys
|
||||
import shutil
|
||||
import time
|
||||
from collections import defaultdict
|
||||
|
||||
from Debug import Debug
|
||||
|
@ -18,11 +20,18 @@ class PluginManager:
|
|||
self.after_load = [] # Execute functions after loaded plugins
|
||||
|
||||
sys.path.append(self.plugin_path)
|
||||
self.migratePlugins()
|
||||
|
||||
if config.debug: # Auto reload Plugins on file change
|
||||
from Debug import DebugReloader
|
||||
DebugReloader(self.reloadPlugins)
|
||||
|
||||
def migratePlugins(self):
|
||||
for dir_name in os.listdir(self.plugin_path):
|
||||
if dir_name == "Mute":
|
||||
self.log.info("Deleting deprecated/renamed plugin: %s" % dir_name)
|
||||
shutil.rmtree("%s/%s" % (self.plugin_path, dir_name))
|
||||
|
||||
# -- Load / Unload --
|
||||
|
||||
# Load all plugin
|
||||
|
|
Loading…
Reference in a new issue