Missing required icon file. The bundle does not contain an app icon for iPhone / iPod Touch of exactly '120x120' pixels

前端 未结 17 3897
眼角桃花
眼角桃花 2021-02-19 17:05

My recent App Store upload gave me this error:

iTunes Store operation failed.
Missing required icon file. The bundle does not contain an app icon for iPhone / iP         


        
17条回答
  •  甜味超标
    2021-02-19 17:33

    I was able to resolve the issue by copying the below-given code in PodFile.

    post_install do |installer|
      copy_pods_resources_path = "Pods/Target Support Files/Pods-PROJECT_NAME/Pods-PROJECT_NAME-resources.sh"
      string_to_replace = '--compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}"'
      assets_compile_with_app_icon_arguments = '--compile "${BUILT_PRODUCTS_DIR}/${UNLOCALIZED_RESOURCES_FOLDER_PATH}" --app-icon "${ASSETCATALOG_COMPILER_APPICON_NAME}" --output-partial-info-plist "${BUILD_DIR}/assetcatalog_generated_info.plist"'
      text = File.read(copy_pods_resources_path)
      new_contents = text.gsub(string_to_replace, assets_compile_with_app_icon_arguments)
      File.open(copy_pods_resources_path, "w") {|file| file.puts new_contents }
    end
    

    Let me know, if this works for you.

提交回复
热议问题