Skip to content

Commit

Permalink
More Edits for linux client installs
Browse files Browse the repository at this point in the history
  • Loading branch information
sfaber34 committed May 9, 2024
1 parent 63d02fe commit 5a85ea7
Showing 1 changed file with 21 additions and 2 deletions.
23 changes: 21 additions & 2 deletions packages/nextjs/public/bgnodes.js
Original file line number Diff line number Diff line change
Expand Up @@ -58,8 +58,27 @@ args.forEach((val, index) => {
});

function checkMacLinuxPrereqs(platform) {
// TODO: Check for/install curl using apt-get on linux
// sudo apt-get install git
if (platform === "linux") {
try {
execSync(`command -v curl`, { stdio: "ignore" });
const version = execSync(`curl -v`).toString().trim();
color("36", `Curl is already installed. Version:\n${version}`);
} catch {
console.log(`Please install Curl by running this command:`);
color("4", `apt-get install curl`);
process.exit(0);
}
}

try {
execSync(`command -v git`, { stdio: "ignore" });
const version = execSync(`git -v`).toString().trim();
color("36", `git is already installed. Version:\n${version}`);
} catch {
console.log(`Please install git by running this command:`);
color("4", `apt-get install git`);
process.exit(0);
}

try {
execSync(`command -v brew`, { stdio: "ignore" });
Expand Down

0 comments on commit 5a85ea7

Please sign in to comment.