From 29a8c9d2355d0a843cb23e2f85a45958dd992293 Mon Sep 17 00:00:00 2001 From: Brian Zalewski Date: Wed, 4 Jan 2023 07:05:17 +0000 Subject: [PATCH] Update file executable_install-program --- home/dot_local/bin/executable_install-program | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/home/dot_local/bin/executable_install-program b/home/dot_local/bin/executable_install-program index fa0db521..7b8bc334 100644 --- a/home/dot_local/bin/executable_install-program +++ b/home/dot_local/bin/executable_install-program @@ -890,9 +890,15 @@ async function ensurePackageManager(packageManager) { log('info', logStage, `\`flatpak\` was installed. It may require a reboot to function correctly.`) } } else if (packageManager === 'gem') { - await ensureInstalled('gem', $`brew install ruby`) + const gem = which.sync('gem', { nothrow: true }) + if (!gem) { + await ensureInstalled('gem', $`brew install ruby`) + } } else if (packageManager === 'go') { - await ensureInstalled('gem', $`brew install go`) + const go = which.sync('go', { nothrow: true }) + if (!go) { + await ensureInstalled('go', $`brew install go`) + } } else if (packageManager === 'nix') { await ensureInstalled( 'nix',