I'm consuming command-exists as follows (only relevant code included):
import commandExists from 'command-exists';
import { promisify } from 'util';
const doesCommandExist = promisify(commandExists);
const configure = async () => {
const isNVMInstalled = await doesCommandExist('nvm');
const isDockerInstalled = await doesCommandExist('docker');
console.log({ isNVMInstalled, isDockerInstalled });
};
configure();
Both are installed and usable from the command line. The output I get is:
{ isNVMInstalled: false, isDockerInstalled: true }
I'm on
MacOS Catalina 10.15.6 (19G73)
Node v12.16.3
I'm consuming command-exists as follows (only relevant code included):
Both are installed and usable from the command line. The output I get is:
{ isNVMInstalled: false, isDockerInstalled: true }I'm on
MacOS Catalina 10.15.6 (19G73)
Node v12.16.3