























@@ -47,6 +47,10 @@ PUBLIC_METADATA_FILENAMES = [
4747"subtitle.txt",
4848"support_url.txt"
4949].freeze
50+APP_REVIEW_NOTES_METADATA_FILENAMES = [
51+"notes.txt",
52+"review_notes.txt"
53+].freeze
50545155def load_env_file(path)
5256return unless File.exist?(path)
@@ -732,6 +736,37 @@ def release_notes_metadata_path
732736temp_root
733737end
734738739+def app_review_notes_markdown_path
740+File.join(ios_root, "APP-REVIEW-NOTES.md")
741+end
742+743+def app_review_notes_pdf_path
744+File.join(ios_root, "build", "app-review", "APP-REVIEW-NOTES.pdf")
745+end
746+747+def generate_app_review_notes_pdf!
748+source = app_review_notes_markdown_path
749+UI.user_error!("Missing App Review notes at #{source}.") unless File.exist?(source)
750+751+output = app_review_notes_pdf_path
752+FileUtils.mkdir_p(File.dirname(output))
753+sh(shell_join(["xcrun", "swift", File.join(repo_root, "scripts", "ios-app-review-notes-pdf.swift"), source, output]))
754+output
755+end
756+757+def assert_no_app_review_notes_field_metadata!(metadata_path)
758+notes_dir = File.join(metadata_path, "review_information")
759+APP_REVIEW_NOTES_METADATA_FILENAMES.each do |filename|
760+path = File.join(notes_dir, filename)
761+next unless File.exist?(path)
762+763+UI.user_error!(
764+"Refusing to upload App Review Notes metadata from #{path}. " \
765+"Maintain the App Store Connect Notes field manually so the live setup code is not stored in this repo."
766+)
767+end
768+end
769+735770def public_metadata_path
736771source = File.join(__dir__, "metadata")
737772temp_root = Dir.mktmpdir("openclaw-app-store-metadata")
@@ -1014,7 +1049,7 @@ platform :ios do
10141049ENV.delete("XCODE_XCCONFIG_FILE")
10151050end
101610511017-desc "Generate screenshots, update App Store version metadata, then upload an App Store build"
1052+desc "Generate screenshots, update App Store metadata and review attachment, then upload an App Store build"
10181053lane :release_upload do
10191054unless ENV["OPENCLAW_IOS_RELEASE_WRAPPER"] == "1"
10201055UI.user_error!("Use `pnpm ios:release:upload`; direct Fastlane TestFlight upload is disabled.")
@@ -1044,7 +1079,7 @@ platform :ios do
10441079ENV.delete("XCODE_XCCONFIG_FILE")
10451080end
104610811047-desc "Upload App Store metadata (and optionally screenshots)"
1082+desc "Upload App Store metadata, App Review PDF attachment, and optionally screenshots"
10481083lane :metadata do
10491084install_ready_for_review_edit_state_lookup!
10501085sync_ios_versioning!
@@ -1064,12 +1099,15 @@ platform :ios do
10641099validate_required_screenshots!(paths)
10651100end
106611011102+assert_no_app_review_notes_field_metadata!(File.join(__dir__, "metadata"))
10671103metadata_path = public_metadata_path
10681104skip_metadata = ENV["DELIVER_METADATA"] != "1"
10691105if release_notes_upload_requested? && skip_metadata
10701106metadata_path = release_notes_metadata_path
10711107skip_metadata = false
10721108end
1109+assert_no_app_review_notes_field_metadata!(metadata_path) unless skip_metadata
1110+app_review_attachment_file = skip_metadata ? nil : generate_app_review_notes_pdf!
1073111110741112deliver_options = {
10751113api_key: api_key,
@@ -1083,6 +1121,7 @@ platform :ios do
10831121skip_metadata: skip_metadata,
10841122skip_binary_upload: true,
10851123overwrite_screenshots: screenshot_upload_requested?,
1124+app_review_attachment_file: app_review_attachment_file,
10861125skip_app_version_update: false,
10871126submit_for_review: false,
10881127run_precheck_before_submit: false
此内容由惯性聚合(RSS阅读器)自动聚合整理,仅供阅读参考。 原文来自 — 版权归原作者所有。