diff --git a/lib/PlugsManager.vala b/lib/PlugsManager.vala index 75d0eaf..c227908 100644 --- a/lib/PlugsManager.vala +++ b/lib/PlugsManager.vala @@ -34,10 +34,18 @@ public class Switchboard.PlugsManager : GLib.Object { private Gee.LinkedList plugs; public signal void plug_added (Switchboard.Plug plug); - + private PlugsManager () { plugs = new Gee.LinkedList (); - var base_folder = File.new_for_path (Build.PLUGS_DIR); + + var plugs_path = Environment.get_variable("SWITCHBOARD_PLUGS_PATH"); + if (plugs_path != null) { + debug ("SWITCHBOARD_PLUGS_PATH set to %s", plugs_path); + } else { + critical ("SWITCHBOARD_PLUGS_PATH not set"); + } + + var base_folder = File.new_for_path (plugs_path); find_plugins (base_folder); }