From 93f378cf39680a9d6b21a9311ef9a94f20dfe067 Mon Sep 17 00:00:00 2001 From: Anton Kastritskiy Date: Thu, 23 May 2024 08:02:44 -0700 Subject: [PATCH] provide full command to run for xcode-select Reviewed By: passy Differential Revision: D57724432 fbshipit-source-id: 94aeeed2005c2318ffcf5850c85e08f123c70879 --- desktop/flipper-common/src/doctor.tsx | 7 ++++++- .../flipper-ui/src/sandy-chrome/doctor/index.tsx | 15 ++++++++++++++- 2 files changed, 20 insertions(+), 2 deletions(-) diff --git a/desktop/flipper-common/src/doctor.tsx b/desktop/flipper-common/src/doctor.tsx index ce7fce328b4..e4ac0e05a64 100644 --- a/desktop/flipper-common/src/doctor.tsx +++ b/desktop/flipper-common/src/doctor.tsx @@ -170,7 +170,12 @@ export namespace FlipperDoctor { 'ios.xcode-select--not_set': [{message: string}]; 'ios.xcode-select--no_xcode_selected': []; 'ios.xcode-select--noop': []; - 'ios.xcode-select--custom_path': []; + 'ios.xcode-select--custom_path': [ + { + selectedPath: string; + availableXcode: string | null; + }, + ]; 'ios.xcode-select--old_version_selected': [ { selectedVersion: string; diff --git a/desktop/flipper-ui/src/sandy-chrome/doctor/index.tsx b/desktop/flipper-ui/src/sandy-chrome/doctor/index.tsx index db881099e2f..898794b679a 100644 --- a/desktop/flipper-ui/src/sandy-chrome/doctor/index.tsx +++ b/desktop/flipper-ui/src/sandy-chrome/doctor/index.tsx @@ -187,6 +187,19 @@ const XcodeSelectNoXcode = ( ); +const XcodeSelectCustomPath = ( + props: PropsFor<'ios.xcode-select--custom_path'>, +) => ( + + Selected path is not a Xcode application: + {props.selectedPath} + /Xcode.app'}`} + /> + +); + const XcodeSelectNonExistingSelected = ( props: PropsFor<'ios.xcode-select--nonexisting_selected'>, ) => ( @@ -335,7 +348,7 @@ const messageToComp: { 'ios.xcode-select--no_xcode_selected': XcodeSelectNoXcode, 'ios.xcode-select--nonexisting_selected': XcodeSelectNonExistingSelected, 'ios.xcode-select--noop': Noop, - 'ios.xcode-select--custom_path': Noop, + 'ios.xcode-select--custom_path': XcodeSelectCustomPath, 'ios.xcode-select--old_version_selected': Noop, 'ios.sdk--installed': IosSdkInstalled,