From 055d49e0f39703a78936fcd663e5ddbafdb0d6c3 Mon Sep 17 00:00:00 2001 From: Brian Zalewski Date: Mon, 2 Sep 2024 21:42:08 -0400 Subject: [PATCH] Update home/.local/bin/installx Update home/.local/bin/package.json --- home/dot_local/bin/executable_installx | 4 +++- home/dot_local/bin/package.json | 5 +++-- 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/home/dot_local/bin/executable_installx b/home/dot_local/bin/executable_installx index faca7889..9ceeb521 100644 --- a/home/dot_local/bin/executable_installx +++ b/home/dot_local/bin/executable_installx @@ -1,5 +1,6 @@ #!/usr/bin/env zx import osInfo from 'linux-os-info' +import parallelLimit from 'async/parallelLimit' $.verbose = false // Preserves color from subshells @@ -387,7 +388,8 @@ async function installPackages(pkgInstructions) { } log(`Performing ${promises.length} installations`) process.env.DEBUG && console.log('Queued installs:', promises) - const installs = await Promise.allSettled(promises) + # const installs = await Promise.allSettled(promises) + const installs = await prallelLimit(promises, 5) log(`All of the installations have finished`) process.env.DEBUG && console.log('Completed installs:', installs) await postInstall(combined) diff --git a/home/dot_local/bin/package.json b/home/dot_local/bin/package.json index 393c9bf7..fae55b2c 100644 --- a/home/dot_local/bin/package.json +++ b/home/dot_local/bin/package.json @@ -12,6 +12,7 @@ "author": "", "license": "MIT", "dependencies": { - "linux-os-info": "2.0.0" + "linux-os-info": "2.0.0", + "async": "3.2.6" } - } \ No newline at end of file + }