Check instruments are on path

Reviewed By: mweststrate

Differential Revision: D18427166

fbshipit-source-id: be075a23d2f0216ac79fc8bd8e083a351e9dbbc9
This commit is contained in:
John Knox
2019-11-12 06:53:57 -08:00
committed by Facebook Github Bot
parent 55cfe11e2c
commit 802c857578

View File

@@ -77,6 +77,21 @@ export function getHealthchecks(): Healthchecks {
.length < 1,
}),
},
{
label: 'Does Instruments exist',
isRequired: true,
run: async (_: EnvironmentInfo) => {
const hasInstruments = await promisify(exec)(
'which instruments',
)
.then(_ => true)
.catch(_ => false);
return {
hasProblem: !hasInstruments,
};
},
},
],
},
}