OPS: Catalyst

This commit is contained in:
Marcos Rodriguez 2026-02-18 18:46:44 -05:00
parent f433968b36
commit 0905c28989
2 changed files with 87 additions and 0 deletions

View File

@ -0,0 +1,54 @@
name: Build Mac Catalyst
on:
workflow_dispatch:
pull_request:
branches:
- master
types: [opened, synchronize, reopened]
jobs:
build-mac-catalyst:
runs-on: macos-15
timeout-minutes: 120
steps:
- name: Checkout project
uses: actions/checkout@v6
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v6
with:
node-version: 24
cache: npm
cache-dependency-path: package-lock.json
- name: Setup Xcode
uses: maxim-lobanov/setup-xcode@v1
with:
xcode-version: latest
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: 3.1.6
bundler-cache: true
- name: Install Node modules
run: npm ci --omit=dev --yes
- name: Install CocoaPods dependencies
run: bundle exec fastlane ios install_pods
- name: Build Mac Catalyst app with Fastlane
id: build_catalyst
run: bundle exec fastlane ios build_catalyst_app_lane
- name: Upload Mac Catalyst artifact
uses: actions/upload-artifact@v6
with:
name: bluewallet-mac-catalyst-app
path: ${{ steps.build_catalyst.outputs.catalyst_app_path }}
if-no-files-found: error

View File

@ -459,6 +459,39 @@ platform :ios do
clean_install: true)
end
desc "Build Mac Catalyst app"
lane :build_catalyst_app_lane do
Dir.chdir(project_root) do
UI.message("Building Mac Catalyst application from: #{Dir.pwd}")
workspace_path = File.join(project_root, "ios", "BlueWallet.xcworkspace")
derived_data_path = File.join(project_root, "ios", "build", "catalyst-derived-data")
clear_derived_data_lane
FileUtils.mkdir_p(derived_data_path)
build_app(
scheme: "BlueWallet",
workspace: workspace_path,
configuration: "Release",
destination: "generic/platform=macOS,variant=Mac Catalyst",
clean: true,
skip_codesigning: true,
skip_package_ipa: true,
derived_data_path: derived_data_path,
buildlog_path: File.join(project_root, "ios", "build_logs")
)
catalyst_app_path = Dir.glob(File.join(derived_data_path, "Build/Products/Release-maccatalyst/*.app")).first
UI.user_error!("Mac Catalyst app was not found after build") if catalyst_app_path.nil?
ENV['CATALYST_APP_PATH'] = catalyst_app_path
sh("echo 'catalyst_app_path=#{catalyst_app_path}' >> $GITHUB_OUTPUT") if ENV['GITHUB_OUTPUT']
UI.success("Mac Catalyst app built at: #{catalyst_app_path}")
end
end
desc "Upload IPA to TestFlight"
lane :upload_to_testflight_lane do