MacOS app to be built on each release build
Summary:
So far we have used a 'template' approach, in which the release build script will copy and use to create the final deliverable.
The template itself was updated locally by running:
cd ~/fbsource/xplat/sonar/facebook/flipper-server
yarn start
This would:
- Build the MacOS app for all supported architectures: x64 and arm64
- Update the template found on the static directory
After the update, we would just commit the changes to the repo.
## About this change
Instead, build the MacOS app when the release script is used. This is leaves way less margin for error as we have removed all the manual steps that had to be done as listed above.
Reviewed By: antonk52
Differential Revision: D51397661
fbshipit-source-id: 2234c9996fa98f32db244764acf3e35dc9a388c9
This commit is contained in:
committed by
Facebook GitHub Bot
parent
b9fa86e77f
commit
e3038a3393
@@ -746,12 +746,28 @@ async function setUpMacBundle(
|
||||
|
||||
let appTemplate = path.join(staticDir, 'flipper-server-app-template');
|
||||
if (isFB) {
|
||||
const {BuildArchitecture, buildFlipperServer} = await import(
|
||||
// @ts-ignore only used inside Meta
|
||||
'./fb/build-flipper-server-macos'
|
||||
);
|
||||
|
||||
const architecture =
|
||||
platform === BuildPlatform.MAC_AARCH64
|
||||
? BuildArchitecture.MAC_AARCH64
|
||||
: BuildArchitecture.MAC_X64;
|
||||
const outputPath = await buildFlipperServer(architecture);
|
||||
console.log(
|
||||
`⚙️ Successfully built platform: ${platform}, output: ${outputPath}`,
|
||||
);
|
||||
|
||||
appTemplate = path.join(
|
||||
staticDir,
|
||||
'facebook',
|
||||
'flipper-server-app-template',
|
||||
platform,
|
||||
);
|
||||
|
||||
await fs.copy(outputPath, path.join(appTemplate, 'Flipper.app'));
|
||||
console.info('⚙️ Using internal template from: ' + appTemplate);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user