flipper-doctor
Version:
Utility for checking for issues with a flipper installation
34 lines • 1.3 kB
JavaScript
;
/**
* Copyright (c) Meta Platforms, Inc. and affiliates.
*
* This source code is licensed under the MIT license found in the
* LICENSE file in the root directory of this source tree.
*
* @format
*/
Object.defineProperty(exports, "__esModule", { value: true });
const index_1 = require("./index");
const environmentInfo_1 = require("./environmentInfo");
(async () => {
const environmentInfo = await (0, environmentInfo_1.getEnvInfo)();
console.log(JSON.stringify(environmentInfo));
const healthchecks = (0, index_1.getHealthchecks)(false);
const results = await Promise.all(Object.entries(healthchecks).map(async ([key, category]) => [
key,
category.isSkipped
? category
: {
label: category.label,
results: await Promise.all(category.healthchecks.map(async ({ key, label, run }) => ({
key,
label,
// TODO: Fix this the next time the file is edited.
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
result: await run(environmentInfo),
}))),
},
]));
console.log(JSON.stringify(results, null, 2));
})();
//# sourceMappingURL=cli.js.map