diff --git a/home/dot_local/bin/executable_install-program b/home/dot_local/bin/executable_install-program index 1f4c1457..6fc7d2bd 100644 --- a/home/dot_local/bin/executable_install-program +++ b/home/dot_local/bin/executable_install-program @@ -1774,12 +1774,22 @@ async function installPlugins(pluginData) { for (const plugin of pluginData.plugins) { try { const pluginCmd = pluginData.cmd.replace(/{PLUGIN}/g, plugin) - runCommand(`Installing ${pluginData.package} plugin - ${plugin}`, pluginCmd) - log('success', 'Plugin', `Successfully installed ${pluginData.package} plugin - ${plugin}`) + const pluginWhen = pluginData.when + try { + if (pluginWhen) { + runCommand(`Checking when condition for ${pluginData.package} plugin - ${plugin}`, pluginWhen) + } + runCommand(`Installing ${pluginData.package} plugin - ${plugin}`, pluginCmd) + log('success', 'Plugin', `Successfully installed ${pluginData.package} plugin - ${plugin}`) + } catch (e) { + log('info', 'Plugin', `Failed to install ${pluginData.package} plugin - ${plugin}`) + console.error(e) + } } catch (e) { - log('error', 'Plugin', `Failed to install ${pluginData.package} plugin - ${plugin}`) + log('error', 'Plugin', `Failed to install ${pluginData.package} plugin - ${plugin`) console.error(e) } + } } if (pluginData.update) { diff --git a/software.yml b/software.yml index c82875a9..86976b89 100644 --- a/software.yml +++ b/software.yml @@ -10798,6 +10798,7 @@ softwarePlugins: - redhatdeveloper/openshift-dd-ext - snyk/snyk-docker-desktop-extension - tailscale/docker-extension:1.0.0 + when: docker extension &>2 /dev/null dockerImages: cmd: null plugins: