nixpkgs mirror (for testing) github.com/NixOS/nixpkgs
nix
at python-updates 23 lines 1.1 kB view raw
1diff --git a/PluginManager.cpp b/PluginManager.cpp 2index 157b6cd5..42d9b59d 100644 3--- a/PluginManager.cpp 4+++ b/PluginManager.cpp 5@@ -59,6 +59,18 @@ void PluginManager::ScanAndLoadPlugins() 6 filesystem::path plugins_dir = ResourceManager::get()->GetConfigurationDirectory() / plugins_path; 7 ScanAndLoadPluginsFrom(plugins_dir, false); 8 9+ /*---------------------------------------------------------*\ 10+ | Get the system plugins directory from the environment | 11+ | | 12+ | Allow setting a system plugin directory during runtime, | 13+ | e.g. by Nixpkgs' `withPlugins` wrapper. | 14+ \*---------------------------------------------------------*/ 15+ const char* system_plugins_dir = std::getenv("OPENRGB_SYSTEM_PLUGIN_DIRECTORY"); 16+ if(system_plugins_dir && *system_plugins_dir) 17+ { 18+ ScanAndLoadPluginsFrom(system_plugins_dir, true); 19+ } 20+ 21 #ifdef OPENRGB_SYSTEM_PLUGIN_DIRECTORY 22 /*---------------------------------------------------------*\ 23 | Get the system plugins directory |