diff --git a/app/plugins/core/plugins/blacklist.js b/app/plugins/core/plugins/blacklist.js new file mode 100644 index 00000000..05769335 --- /dev/null +++ b/app/plugins/core/plugins/blacklist.js @@ -0,0 +1,8 @@ +/** + * This file contains plugins that have been blacklisted. + * The main purpose of this is to hide plugins that have been republished under our scope. + * The name must match (case sensitive) the name in the `package.json`. + */ +export default [ + 'cerebro-basic-apps' // @cerebroapp/cerebro-basic-apps +] diff --git a/app/plugins/core/plugins/loadPlugins.js b/app/plugins/core/plugins/loadPlugins.js index 6bf77039..29f143c3 100644 --- a/app/plugins/core/plugins/loadPlugins.js +++ b/app/plugins/core/plugins/loadPlugins.js @@ -4,6 +4,7 @@ import compareVersions from 'semver/functions/gt' import availablePlugins from './getAvailablePlugins' import getInstalledPlugins from './getInstalledPlugins' import getDebuggingPlugins from './getDebuggingPlugins' +import blacklist from './blacklist' const maxAge = 5 * 60 * 1000 // 5 minutes @@ -50,9 +51,11 @@ export default async () => { isDebugging: true })) - return [ + const plugins = [ ...listOfInstalledPlugins, ...listOfAvailablePlugins, ...listOfDebuggingPlugins - ] + ].filter((plugin) => !blacklist.includes(plugin.name)) + + return plugins }