fastlane_hotfix 2.165.1 → 2.187.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE +1 -1
- data/README.md +106 -86
- data/cert/lib/cert/commands_generator.rb +2 -1
- data/cert/lib/cert/options.rb +6 -5
- data/cert/lib/cert/runner.rb +8 -8
- data/deliver/lib/assets/summary.html.erb +10 -10
- data/deliver/lib/deliver/app_screenshot.rb +17 -11
- data/deliver/lib/deliver/app_screenshot_validator.rb +108 -0
- data/deliver/lib/deliver/commands_generator.rb +4 -3
- data/deliver/lib/deliver/detect_values.rb +5 -3
- data/deliver/lib/deliver/download_screenshots.rb +2 -3
- data/deliver/lib/deliver/html_generator.rb +2 -2
- data/deliver/lib/deliver/languages.rb +1 -1
- data/deliver/lib/deliver/loader.rb +123 -21
- data/deliver/lib/deliver/module.rb +6 -0
- data/deliver/lib/deliver/options.rb +41 -55
- data/deliver/lib/deliver/runner.rb +19 -14
- data/deliver/lib/deliver/setup.rb +9 -5
- data/deliver/lib/deliver/submit_for_review.rb +4 -4
- data/deliver/lib/deliver/upload_metadata.rb +32 -21
- data/deliver/lib/deliver/upload_price_tier.rb +1 -1
- data/deliver/lib/deliver/upload_screenshots.rb +14 -76
- data/fastlane/lib/fastlane/actions/actions_helper.rb +3 -3
- data/fastlane/lib/fastlane/actions/adb.rb +2 -5
- data/fastlane/lib/fastlane/actions/adb_devices.rb +0 -1
- data/fastlane/lib/fastlane/actions/add_git_tag.rb +22 -6
- data/fastlane/lib/fastlane/actions/app_store_build_number.rb +17 -17
- data/fastlane/lib/fastlane/actions/app_store_connect_api_key.rb +21 -7
- data/fastlane/lib/fastlane/actions/appaloosa.rb +7 -2
- data/fastlane/lib/fastlane/actions/appetize.rb +13 -8
- data/fastlane/lib/fastlane/actions/appetize_viewing_url_generator.rb +0 -11
- data/fastlane/lib/fastlane/actions/appium.rb +40 -65
- data/fastlane/lib/fastlane/actions/appledoc.rb +46 -46
- data/fastlane/lib/fastlane/actions/apteligent.rb +3 -2
- data/fastlane/lib/fastlane/actions/artifactory.rb +41 -9
- data/fastlane/lib/fastlane/actions/automatic_code_signing.rb +7 -13
- data/fastlane/lib/fastlane/actions/backup_file.rb +1 -1
- data/fastlane/lib/fastlane/actions/backup_xcarchive.rb +3 -3
- data/fastlane/lib/fastlane/actions/badge.rb +9 -13
- data/fastlane/lib/fastlane/actions/build_and_upload_to_appetize.rb +11 -5
- data/fastlane/lib/fastlane/actions/build_app.rb +7 -1
- data/fastlane/lib/fastlane/actions/bundle_install.rb +8 -10
- data/fastlane/lib/fastlane/actions/carthage.rb +22 -14
- data/fastlane/lib/fastlane/actions/changelog_from_git_commits.rb +8 -17
- data/fastlane/lib/fastlane/actions/chatwork.rb +3 -2
- data/fastlane/lib/fastlane/actions/check_app_store_metadata.rb +9 -1
- data/fastlane/lib/fastlane/actions/clean_build_artifacts.rb +0 -1
- data/fastlane/lib/fastlane/actions/clean_cocoapods_cache.rb +0 -1
- data/fastlane/lib/fastlane/actions/clipboard.rb +3 -6
- data/fastlane/lib/fastlane/actions/cloc.rb +9 -13
- data/fastlane/lib/fastlane/actions/cocoapods.rb +23 -15
- data/fastlane/lib/fastlane/actions/commit_github_file.rb +12 -4
- data/fastlane/lib/fastlane/actions/commit_version_bump.rb +6 -7
- data/fastlane/lib/fastlane/actions/copy_artifacts.rb +3 -4
- data/fastlane/lib/fastlane/actions/crashlytics.rb +7 -11
- data/fastlane/lib/fastlane/actions/create_app_on_managed_play_store.rb +70 -76
- data/fastlane/lib/fastlane/actions/create_keychain.rb +13 -11
- data/fastlane/lib/fastlane/actions/create_pull_request.rb +15 -9
- data/fastlane/lib/fastlane/actions/create_xcframework.rb +123 -0
- data/fastlane/lib/fastlane/actions/danger.rb +13 -12
- data/fastlane/lib/fastlane/actions/deploygate.rb +1 -2
- data/fastlane/lib/fastlane/actions/docs/build_app.md +1 -1
- data/fastlane/lib/fastlane/actions/docs/capture_android_screenshots.md +27 -28
- data/fastlane/lib/fastlane/actions/docs/capture_ios_screenshots.md +7 -3
- data/fastlane/lib/fastlane/actions/docs/create_app_online.md +171 -67
- data/fastlane/lib/fastlane/actions/docs/frame_screenshots.md +20 -3
- data/fastlane/lib/fastlane/actions/docs/sync_code_signing.md +9 -3
- data/fastlane/lib/fastlane/actions/docs/upload_to_app_store.md.erb +39 -16
- data/fastlane/lib/fastlane/actions/docs/upload_to_play_store.md +2 -1
- data/fastlane/lib/fastlane/actions/docs/upload_to_testflight.md +15 -5
- data/fastlane/lib/fastlane/actions/download_app_privacy_details_from_app_store.rb +142 -0
- data/fastlane/lib/fastlane/actions/download_dsyms.rb +8 -20
- data/fastlane/lib/fastlane/actions/dsym_zip.rb +1 -1
- data/fastlane/lib/fastlane/actions/ensure_env_vars.rb +2 -6
- data/fastlane/lib/fastlane/actions/ensure_git_branch.rb +0 -1
- data/fastlane/lib/fastlane/actions/ensure_git_status_clean.rb +3 -4
- data/fastlane/lib/fastlane/actions/ensure_no_debug_code.rb +3 -5
- data/fastlane/lib/fastlane/actions/ensure_xcode_version.rb +1 -2
- data/fastlane/lib/fastlane/actions/environment_variable.rb +13 -21
- data/fastlane/lib/fastlane/actions/erb.rb +2 -5
- data/fastlane/lib/fastlane/actions/get_build_number_repository.rb +1 -1
- data/fastlane/lib/fastlane/actions/get_certificates.rb +5 -1
- data/fastlane/lib/fastlane/actions/get_github_release.rb +11 -1
- data/fastlane/lib/fastlane/actions/get_ipa_info_plist_value.rb +0 -1
- data/fastlane/lib/fastlane/actions/get_managed_play_store_publishing_rights.rb +32 -35
- data/fastlane/lib/fastlane/actions/get_provisioning_profile.rb +9 -1
- data/fastlane/lib/fastlane/actions/get_push_certificate.rb +1 -1
- data/fastlane/lib/fastlane/actions/get_version_number.rb +17 -10
- data/fastlane/lib/fastlane/actions/git_add.rb +5 -10
- data/fastlane/lib/fastlane/actions/git_branch.rb +4 -10
- data/fastlane/lib/fastlane/actions/git_commit.rb +12 -10
- data/fastlane/lib/fastlane/actions/git_pull.rb +4 -10
- data/fastlane/lib/fastlane/actions/git_remote_branch.rb +57 -0
- data/fastlane/lib/fastlane/actions/git_submodule_update.rb +16 -8
- data/fastlane/lib/fastlane/actions/git_tag_exists.rb +4 -0
- data/fastlane/lib/fastlane/actions/github_api.rb +17 -8
- data/fastlane/lib/fastlane/actions/gradle.rb +12 -20
- data/fastlane/lib/fastlane/actions/hg_commit_version_bump.rb +1 -1
- data/fastlane/lib/fastlane/actions/hg_push.rb +1 -1
- data/fastlane/lib/fastlane/actions/hipchat.rb +6 -6
- data/fastlane/lib/fastlane/actions/hockey.rb +5 -12
- data/fastlane/lib/fastlane/actions/ifttt.rb +3 -6
- data/fastlane/lib/fastlane/actions/import_from_git.rb +7 -9
- data/fastlane/lib/fastlane/actions/increment_build_number.rb +8 -2
- data/fastlane/lib/fastlane/actions/install_on_device.rb +3 -6
- data/fastlane/lib/fastlane/actions/install_provisioning_profile.rb +4 -0
- data/fastlane/lib/fastlane/actions/installr.rb +22 -25
- data/fastlane/lib/fastlane/actions/ipa.rb +2 -2
- data/fastlane/lib/fastlane/actions/jazzy.rb +11 -8
- data/fastlane/lib/fastlane/actions/jira.rb +61 -14
- data/fastlane/lib/fastlane/actions/latest_testflight_build_number.rb +6 -6
- data/fastlane/lib/fastlane/actions/lcov.rb +0 -4
- data/fastlane/lib/fastlane/actions/mailgun.rb +21 -27
- data/fastlane/lib/fastlane/actions/make_changelog_from_jenkins.rb +1 -1
- data/fastlane/lib/fastlane/actions/match_nuke.rb +59 -0
- data/fastlane/lib/fastlane/actions/modify_services.rb +59 -24
- data/fastlane/lib/fastlane/actions/nexus_upload.rb +3 -2
- data/fastlane/lib/fastlane/actions/notarize.rb +98 -54
- data/fastlane/lib/fastlane/actions/notification.rb +1 -1
- data/fastlane/lib/fastlane/actions/number_of_commits.rb +1 -1
- data/fastlane/lib/fastlane/actions/oclint.rb +15 -14
- data/fastlane/lib/fastlane/actions/onesignal.rb +13 -3
- data/fastlane/lib/fastlane/actions/pod_push.rb +9 -2
- data/fastlane/lib/fastlane/actions/podio_item.rb +0 -7
- data/fastlane/lib/fastlane/actions/prompt.rb +3 -4
- data/fastlane/lib/fastlane/actions/push_git_tags.rb +1 -1
- data/fastlane/lib/fastlane/actions/push_to_git_remote.rb +14 -3
- data/fastlane/lib/fastlane/actions/puts.rb +1 -2
- data/fastlane/lib/fastlane/actions/register_device.rb +10 -13
- data/fastlane/lib/fastlane/actions/register_devices.rb +11 -14
- data/fastlane/lib/fastlane/actions/reset_git_repo.rb +5 -8
- data/fastlane/lib/fastlane/actions/reset_simulator_contents.rb +0 -2
- data/fastlane/lib/fastlane/actions/resign.rb +2 -9
- data/fastlane/lib/fastlane/actions/restore_file.rb +1 -1
- data/fastlane/lib/fastlane/actions/rsync.rb +3 -6
- data/fastlane/lib/fastlane/actions/run_tests.rb +1 -1
- data/fastlane/lib/fastlane/actions/s3.rb +1 -1
- data/fastlane/lib/fastlane/actions/say.rb +2 -3
- data/fastlane/lib/fastlane/actions/scp.rb +4 -10
- data/fastlane/lib/fastlane/actions/set_build_number_repository.rb +1 -1
- data/fastlane/lib/fastlane/actions/set_changelog.rb +10 -13
- data/fastlane/lib/fastlane/actions/set_github_release.rb +23 -16
- data/fastlane/lib/fastlane/actions/set_info_plist_value.rb +1 -1
- data/fastlane/lib/fastlane/actions/set_pod_key.rb +3 -4
- data/fastlane/lib/fastlane/actions/setup_ci.rb +1 -2
- data/fastlane/lib/fastlane/actions/setup_circle_ci.rb +1 -1
- data/fastlane/lib/fastlane/actions/setup_jenkins.rb +7 -12
- data/fastlane/lib/fastlane/actions/setup_travis.rb +1 -1
- data/fastlane/lib/fastlane/actions/sh.rb +2 -4
- data/fastlane/lib/fastlane/actions/slack.rb +164 -145
- data/fastlane/lib/fastlane/actions/slather.rb +5 -21
- data/fastlane/lib/fastlane/actions/sonar.rb +12 -19
- data/fastlane/lib/fastlane/actions/sourcedocs.rb +128 -0
- data/fastlane/lib/fastlane/actions/spaceship_logs.rb +1 -1
- data/fastlane/lib/fastlane/actions/splunkmint.rb +2 -2
- data/fastlane/lib/fastlane/actions/spm.rb +8 -2
- data/fastlane/lib/fastlane/actions/ssh.rb +5 -10
- data/fastlane/lib/fastlane/actions/swiftlint.rb +21 -19
- data/fastlane/lib/fastlane/actions/sync_code_signing.rb +6 -1
- data/fastlane/lib/fastlane/actions/testfairy.rb +0 -1
- data/fastlane/lib/fastlane/actions/tryouts.rb +2 -3
- data/fastlane/lib/fastlane/actions/twitter.rb +0 -5
- data/fastlane/lib/fastlane/actions/unlock_keychain.rb +3 -3
- data/fastlane/lib/fastlane/actions/update_app_group_identifiers.rb +1 -4
- data/fastlane/lib/fastlane/actions/update_code_signing_settings.rb +8 -15
- data/fastlane/lib/fastlane/actions/update_fastlane.rb +31 -10
- data/fastlane/lib/fastlane/actions/update_icloud_container_identifiers.rb +1 -4
- data/fastlane/lib/fastlane/actions/update_info_plist.rb +1 -1
- data/fastlane/lib/fastlane/actions/update_keychain_access_groups.rb +1 -4
- data/fastlane/lib/fastlane/actions/update_plist.rb +1 -1
- data/fastlane/lib/fastlane/actions/update_project_provisioning.rb +3 -4
- data/fastlane/lib/fastlane/actions/update_urban_airship_configuration.rb +0 -1
- data/fastlane/lib/fastlane/actions/update_url_schemes.rb +15 -26
- data/fastlane/lib/fastlane/actions/upload_app_privacy_details_to_app_store.rb +290 -0
- data/fastlane/lib/fastlane/actions/upload_symbols_to_crashlytics.rb +8 -7
- data/fastlane/lib/fastlane/actions/upload_symbols_to_sentry.rb +3 -10
- data/fastlane/lib/fastlane/actions/upload_to_app_store.rb +8 -4
- data/fastlane/lib/fastlane/actions/upload_to_testflight.rb +7 -2
- data/fastlane/lib/fastlane/actions/validate_play_store_json_key.rb +40 -44
- data/fastlane/lib/fastlane/actions/version_get_podspec.rb +1 -2
- data/fastlane/lib/fastlane/actions/xcode_install.rb +8 -5
- data/fastlane/lib/fastlane/actions/xcode_server_get_assets.rb +3 -3
- data/fastlane/lib/fastlane/actions/xcodebuild.rb +5 -5
- data/fastlane/lib/fastlane/cli_tools_distributor.rb +6 -3
- data/fastlane/lib/fastlane/commands_generator.rb +2 -1
- data/fastlane/lib/fastlane/documentation/actions_list.rb +2 -2
- data/fastlane/lib/fastlane/documentation/docs_generator.rb +1 -1
- data/fastlane/lib/fastlane/documentation/markdown_docs_generator.rb +1 -1
- data/fastlane/lib/fastlane/environment_printer.rb +1 -0
- data/fastlane/lib/fastlane/erb_template_helper.rb +7 -1
- data/fastlane/lib/fastlane/fast_file.rb +19 -7
- data/fastlane/lib/fastlane/fastlane_require.rb +7 -1
- data/fastlane/lib/fastlane/features.rb +1 -1
- data/fastlane/lib/fastlane/helper/adb_helper.rb +1 -1
- data/fastlane/lib/fastlane/helper/crashlytics_helper.rb +4 -4
- data/fastlane/lib/fastlane/helper/gem_helper.rb +2 -2
- data/fastlane/lib/fastlane/helper/git_helper.rb +34 -5
- data/fastlane/lib/fastlane/lane_manager.rb +3 -2
- data/fastlane/lib/fastlane/notification/slack.rb +56 -0
- data/fastlane/lib/fastlane/plugins/plugin_fetcher.rb +1 -2
- data/fastlane/lib/fastlane/plugins/plugin_info.rb +2 -2
- data/fastlane/lib/fastlane/plugins/plugin_info_collector.rb +1 -2
- data/fastlane/lib/fastlane/plugins/plugin_manager.rb +2 -3
- data/fastlane/lib/fastlane/plugins/template/%gem_name%.gemspec.erb +7 -6
- data/fastlane/lib/fastlane/plugins/template/.circleci/config.yml +1 -1
- data/fastlane/lib/fastlane/plugins/template/.github/workflows/test.yml +1 -1
- data/fastlane/lib/fastlane/plugins/template/.rubocop.yml +31 -35
- data/fastlane/lib/fastlane/plugins/template/spec/spec_helper.rb.erb +1 -1
- data/fastlane/lib/fastlane/setup/setup.rb +23 -10
- data/fastlane/lib/fastlane/setup/setup_ios.rb +3 -3
- data/fastlane/lib/fastlane/swift_fastlane_api_generator.rb +3 -0
- data/fastlane/lib/fastlane/swift_fastlane_function.rb +44 -16
- data/fastlane/lib/fastlane/swift_runner_upgrader.rb +2 -0
- data/fastlane/lib/fastlane/version.rb +2 -2
- data/fastlane/swift/Actions.swift +1 -1
- data/fastlane/swift/Appfile.swift +1 -1
- data/fastlane/swift/ArgumentProcessor.swift +1 -1
- data/fastlane/swift/ControlCommand.swift +1 -1
- data/fastlane/swift/Deliverfile.swift +2 -2
- data/fastlane/swift/DeliverfileProtocol.swift +23 -23
- data/fastlane/swift/Fastfile.swift +1 -1
- data/fastlane/swift/Fastlane.swift +7965 -4213
- data/fastlane/swift/FastlaneSwiftRunner/FastlaneSwiftRunner.xcodeproj/project.pbxproj +4 -0
- data/fastlane/swift/Gymfile.swift +2 -2
- data/fastlane/swift/GymfileProtocol.swift +15 -3
- data/fastlane/swift/LaneFileProtocol.swift +12 -6
- data/fastlane/swift/MainProcess.swift +3 -1
- data/fastlane/swift/Matchfile.swift +2 -2
- data/fastlane/swift/MatchfileProtocol.swift +4 -4
- data/fastlane/swift/OptionalConfigValue.swift +101 -0
- data/fastlane/swift/Plugins.swift +1 -1
- data/fastlane/swift/Precheckfile.swift +2 -2
- data/fastlane/swift/PrecheckfileProtocol.swift +8 -4
- data/fastlane/swift/RubyCommand.swift +2 -2
- data/fastlane/swift/RubyCommandable.swift +1 -1
- data/fastlane/swift/Runner.swift +3 -3
- data/fastlane/swift/RunnerArgument.swift +1 -1
- data/fastlane/swift/Scanfile.swift +2 -2
- data/fastlane/swift/ScanfileProtocol.swift +34 -2
- data/fastlane/swift/Screengrabfile.swift +2 -2
- data/fastlane/swift/ScreengrabfileProtocol.swift +5 -5
- data/fastlane/swift/Snapshotfile.swift +2 -2
- data/fastlane/swift/SnapshotfileProtocol.swift +19 -3
- data/fastlane/swift/SocketClient.swift +4 -3
- data/fastlane/swift/SocketClientDelegateProtocol.swift +1 -1
- data/fastlane/swift/SocketResponse.swift +5 -3
- data/fastlane/swift/formatting/Brewfile.lock.json +24 -16
- data/fastlane/swift/main.swift +1 -1
- data/fastlane/swift/upgrade_manifest.json +1 -1
- data/fastlane_core/lib/fastlane_core.rb +22 -20
- data/fastlane_core/lib/fastlane_core/build_watcher.rb +89 -12
- data/fastlane_core/lib/fastlane_core/cert_checker.rb +12 -7
- data/fastlane_core/lib/fastlane_core/clipboard.rb +20 -0
- data/fastlane_core/lib/fastlane_core/command_executor.rb +3 -9
- data/fastlane_core/lib/fastlane_core/configuration/commander_generator.rb +6 -1
- data/fastlane_core/lib/fastlane_core/configuration/config_item.rb +41 -3
- data/fastlane_core/lib/fastlane_core/configuration/configuration.rb +14 -8
- data/fastlane_core/lib/fastlane_core/device_manager.rb +1 -1
- data/fastlane_core/lib/fastlane_core/helper.rb +78 -14
- data/fastlane_core/lib/fastlane_core/ipa_file_analyser.rb +41 -16
- data/fastlane_core/lib/fastlane_core/ipa_upload_package_builder.rb +3 -2
- data/fastlane_core/lib/fastlane_core/itunes_transporter.rb +20 -15
- data/fastlane_core/lib/fastlane_core/keychain_importer.rb +1 -1
- data/fastlane_core/lib/fastlane_core/languages.rb +2 -2
- data/fastlane_core/lib/fastlane_core/pkg_upload_package_builder.rb +3 -2
- data/fastlane_core/lib/fastlane_core/print_table.rb +5 -3
- data/fastlane_core/lib/fastlane_core/project.rb +48 -28
- data/fastlane_core/lib/fastlane_core/provisioning_profile.rb +3 -1
- data/{deliver/lib/deliver → fastlane_core/lib/fastlane_core}/queue_worker.rb +4 -4
- data/fastlane_core/lib/fastlane_core/swag.rb +1 -1
- data/fastlane_core/lib/fastlane_core/ui/disable_colors.rb +8 -0
- data/fastlane_core/lib/fastlane_core/ui/help.erb +35 -0
- data/fastlane_core/lib/fastlane_core/ui/help_formatter.rb +16 -0
- data/fastlane_core/lib/fastlane_core/ui/implementations/shell.rb +16 -2
- data/fastlane_core/lib/fastlane_core/ui/interface.rb +1 -1
- data/fastlane_core/lib/fastlane_core/update_checker/update_checker.rb +2 -2
- data/frameit/lib/frameit/commands_generator.rb +2 -1
- data/frameit/lib/frameit/config_parser.rb +2 -2
- data/frameit/lib/frameit/device_types.rb +7 -1
- data/frameit/lib/frameit/frame_downloader.rb +2 -1
- data/gym/lib/gym/code_signing_mapping.rb +3 -3
- data/gym/lib/gym/commands_generator.rb +2 -1
- data/gym/lib/gym/error_handler.rb +8 -0
- data/gym/lib/gym/generators/build_command_generator.rb +3 -0
- data/gym/lib/gym/generators/package_command_generator.rb +4 -0
- data/gym/lib/gym/generators/package_command_generator_xcode7.rb +21 -15
- data/gym/lib/gym/options.rb +19 -3
- data/gym/lib/gym/runner.rb +15 -4
- data/match/lib/match/change_password.rb +3 -3
- data/match/lib/match/commands_generator.rb +2 -1
- data/match/lib/match/encryption/interface.rb +1 -1
- data/match/lib/match/encryption/openssl.rb +5 -3
- data/match/lib/match/importer.rb +9 -10
- data/match/lib/match/migrate.rb +2 -3
- data/match/lib/match/module.rb +2 -1
- data/match/lib/match/nuke.rb +19 -15
- data/match/lib/match/options.rb +4 -3
- data/match/lib/match/runner.rb +3 -4
- data/match/lib/match/spaceship_ensure.rb +3 -0
- data/match/lib/match/storage/git_storage.rb +14 -10
- data/match/lib/match/storage/google_cloud_storage.rb +2 -2
- data/match/lib/match/storage/s3_storage.rb +2 -2
- data/pem/lib/pem/commands_generator.rb +2 -1
- data/pilot/lib/pilot.rb +0 -1
- data/pilot/lib/pilot/build_manager.rb +41 -15
- data/pilot/lib/pilot/commands_generator.rb +2 -1
- data/pilot/lib/pilot/manager.rb +11 -8
- data/pilot/lib/pilot/options.rb +18 -9
- data/pilot/lib/pilot/tester_exporter.rb +0 -1
- data/pilot/lib/pilot/tester_manager.rb +0 -1
- data/precheck/lib/precheck/commands_generator.rb +2 -1
- data/precheck/lib/precheck/options.rb +9 -3
- data/precheck/lib/precheck/rule_processor.rb +1 -1
- data/precheck/lib/precheck/runner.rb +14 -9
- data/produce/lib/produce/commands_generator.rb +101 -28
- data/produce/lib/produce/developer_center.rb +42 -4
- data/produce/lib/produce/options.rb +1 -1
- data/produce/lib/produce/service.rb +270 -179
- data/scan/lib/scan/commands_generator.rb +2 -1
- data/scan/lib/scan/detect_values.rb +7 -2
- data/scan/lib/scan/module.rb +4 -0
- data/scan/lib/scan/options.rb +46 -1
- data/scan/lib/scan/runner.rb +88 -3
- data/scan/lib/scan/slack_poster.rb +4 -1
- data/scan/lib/scan/test_command_generator.rb +13 -8
- data/screengrab/lib/screengrab/android_environment.rb +5 -53
- data/screengrab/lib/screengrab/commands_generator.rb +2 -1
- data/screengrab/lib/screengrab/dependency_checker.rb +0 -20
- data/screengrab/lib/screengrab/options.rb +5 -2
- data/screengrab/lib/screengrab/runner.rb +111 -108
- data/sigh/lib/assets/resign.sh +81 -61
- data/sigh/lib/sigh/commands_generator.rb +2 -1
- data/sigh/lib/sigh/download_all.rb +4 -8
- data/sigh/lib/sigh/options.rb +3 -2
- data/sigh/lib/sigh/runner.rb +9 -9
- data/snapshot/lib/assets/SnapfileTemplate +3 -2
- data/snapshot/lib/assets/SnapfileTemplate.swift +2 -1
- data/snapshot/lib/assets/SnapshotHelper.swift +20 -12
- data/snapshot/lib/snapshot/commands_generator.rb +3 -1
- data/snapshot/lib/snapshot/options.rb +22 -2
- data/snapshot/lib/snapshot/reports_generator.rb +7 -1
- data/snapshot/lib/snapshot/simulator_launchers/launcher_configuration.rb +2 -0
- data/snapshot/lib/snapshot/simulator_launchers/simulator_launcher.rb +1 -1
- data/snapshot/lib/snapshot/simulator_launchers/simulator_launcher_base.rb +10 -5
- data/snapshot/lib/snapshot/test_command_generator.rb +18 -4
- data/snapshot/lib/snapshot/test_command_generator_base.rb +3 -1
- data/snapshot/lib/snapshot/test_command_generator_xcode_8.rb +1 -1
- data/snapshot/lib/snapshot/update.rb +1 -1
- data/spaceship/README.md +4 -14
- data/spaceship/lib/spaceship/base.rb +2 -2
- data/spaceship/lib/spaceship/client.rb +47 -29
- data/spaceship/lib/spaceship/commands_generator.rb +4 -2
- data/spaceship/lib/spaceship/connect_api.rb +6 -0
- data/spaceship/lib/spaceship/connect_api/api_client.rb +67 -9
- data/spaceship/lib/spaceship/connect_api/model.rb +1 -1
- data/spaceship/lib/spaceship/connect_api/models/age_rating_declaration.rb +39 -6
- data/spaceship/lib/spaceship/connect_api/models/app.rb +95 -55
- data/spaceship/lib/spaceship/connect_api/models/app_data_usage.rb +59 -0
- data/spaceship/lib/spaceship/connect_api/models/app_data_usage_category.rb +65 -0
- data/spaceship/lib/spaceship/connect_api/models/app_data_usage_data_protection.rb +27 -0
- data/spaceship/lib/spaceship/connect_api/models/app_data_usage_grouping.rb +18 -0
- data/spaceship/lib/spaceship/connect_api/models/app_data_usage_purposes.rb +37 -0
- data/spaceship/lib/spaceship/connect_api/models/app_data_usages_publish_state.rb +36 -0
- data/spaceship/lib/spaceship/connect_api/models/app_info.rb +26 -10
- data/spaceship/lib/spaceship/connect_api/models/app_info_localization.rb +8 -4
- data/spaceship/lib/spaceship/connect_api/models/app_preview.rb +15 -11
- data/spaceship/lib/spaceship/connect_api/models/app_preview_set.rb +18 -9
- data/spaceship/lib/spaceship/connect_api/models/app_screenshot.rb +10 -8
- data/spaceship/lib/spaceship/connect_api/models/app_screenshot_set.rb +20 -11
- data/spaceship/lib/spaceship/connect_api/models/app_store_review_attachment.rb +7 -5
- data/spaceship/lib/spaceship/connect_api/models/app_store_review_detail.rb +6 -4
- data/spaceship/lib/spaceship/connect_api/models/app_store_version.rb +62 -38
- data/spaceship/lib/spaceship/connect_api/models/app_store_version_localization.rb +27 -14
- data/spaceship/lib/spaceship/connect_api/models/app_store_version_submission.rb +3 -2
- data/spaceship/lib/spaceship/connect_api/models/beta_app_review_submission.rb +3 -2
- data/spaceship/lib/spaceship/connect_api/models/beta_feedback.rb +6 -4
- data/spaceship/lib/spaceship/connect_api/models/beta_group.rb +29 -3
- data/spaceship/lib/spaceship/connect_api/models/beta_tester.rb +15 -9
- data/spaceship/lib/spaceship/connect_api/models/build.rb +34 -17
- data/spaceship/lib/spaceship/connect_api/models/build_beta_detail.rb +4 -0
- data/spaceship/lib/spaceship/connect_api/models/build_delivery.rb +3 -2
- data/spaceship/lib/spaceship/connect_api/models/bundle_id.rb +41 -6
- data/spaceship/lib/spaceship/connect_api/models/bundle_id_capability.rb +86 -21
- data/spaceship/lib/spaceship/connect_api/models/certificate.rb +12 -8
- data/spaceship/lib/spaceship/connect_api/models/device.rb +36 -4
- data/spaceship/lib/spaceship/connect_api/models/idfa_declaration.rb +6 -4
- data/spaceship/lib/spaceship/connect_api/models/profile.rb +18 -8
- data/spaceship/lib/spaceship/connect_api/models/reset_ratings_request.rb +3 -2
- data/spaceship/lib/spaceship/connect_api/models/sandbox_tester.rb +9 -6
- data/spaceship/lib/spaceship/connect_api/models/territory.rb +3 -2
- data/spaceship/lib/spaceship/connect_api/models/user.rb +6 -4
- data/spaceship/lib/spaceship/connect_api/models/user_invitation.rb +22 -6
- data/spaceship/lib/spaceship/connect_api/provisioning/provisioning.rb +99 -2
- data/spaceship/lib/spaceship/connect_api/response.rb +3 -1
- data/spaceship/lib/spaceship/connect_api/testflight/testflight.rb +50 -0
- data/spaceship/lib/spaceship/connect_api/token.rb +15 -3
- data/spaceship/lib/spaceship/connect_api/tunes/tunes.rb +122 -2
- data/spaceship/lib/spaceship/errors.rb +19 -0
- data/spaceship/lib/spaceship/playground.rb +2 -2
- data/spaceship/lib/spaceship/spaceauth_runner.rb +38 -15
- data/spaceship/lib/spaceship/tunes/iap_detail.rb +1 -1
- data/spaceship/lib/spaceship/tunes/members.rb +1 -1
- data/spaceship/lib/spaceship/tunes/tunes_client.rb +4 -4
- data/spaceship/lib/spaceship/two_step_or_factor_client.rb +59 -33
- data/spaceship/lib/spaceship/ui.rb +2 -2
- data/spaceship/lib/spaceship/upgrade_2fa_later_client.rb +91 -0
- data/supply/lib/supply.rb +1 -1
- data/supply/lib/supply/client.rb +5 -3
- data/supply/lib/supply/commands_generator.rb +2 -1
- data/supply/lib/supply/options.rb +3 -3
- data/supply/lib/supply/uploader.rb +6 -4
- metadata +125 -93
- data/pilot/lib/pilot/features.rb +0 -0
- data/pilot/lib/pilot/tester_util.rb +0 -0
@@ -10,7 +10,12 @@ module Fastlane
|
|
10
10
|
require 'match'
|
11
11
|
|
12
12
|
params.load_configuration_file("Matchfile")
|
13
|
-
|
13
|
+
|
14
|
+
# Only set :api_key from SharedValues if :api_key_path isn't set (conflicting options)
|
15
|
+
unless params[:api_key_path]
|
16
|
+
params[:api_key] ||= Actions.lane_context[SharedValues::APP_STORE_CONNECT_API_KEY]
|
17
|
+
end
|
18
|
+
|
14
19
|
Match::Runner.new.run(params)
|
15
20
|
|
16
21
|
define_profile_type(params)
|
@@ -192,7 +192,6 @@ module Fastlane
|
|
192
192
|
env_name: "FL_TESTFAIRY_UPLOAD_URL", # The name of the environment variable
|
193
193
|
description: "API URL for TestFairy", # a short description of this parameter
|
194
194
|
default_value: "https://upload.testfairy.com",
|
195
|
-
is_string: true,
|
196
195
|
optional: true),
|
197
196
|
FastlaneCore::ConfigItem.new(key: :testers_groups,
|
198
197
|
optional: true,
|
@@ -91,7 +91,6 @@ module Fastlane
|
|
91
91
|
FastlaneCore::ConfigItem.new(key: :notes,
|
92
92
|
env_name: "TRYOUTS_NOTES",
|
93
93
|
description: "Release notes",
|
94
|
-
is_string: true,
|
95
94
|
optional: true),
|
96
95
|
FastlaneCore::ConfigItem.new(key: :notes_path,
|
97
96
|
env_name: "TRYOUTS_NOTES_PATH",
|
@@ -103,7 +102,7 @@ module Fastlane
|
|
103
102
|
FastlaneCore::ConfigItem.new(key: :notify,
|
104
103
|
env_name: "TRYOUTS_NOTIFY",
|
105
104
|
description: "Notify testers? 0 for no",
|
106
|
-
|
105
|
+
type: Integer,
|
107
106
|
default_value: 1),
|
108
107
|
FastlaneCore::ConfigItem.new(key: :status,
|
109
108
|
env_name: "TRYOUTS_STATUS",
|
@@ -112,7 +111,7 @@ module Fastlane
|
|
112
111
|
available_options = ["1", "2"]
|
113
112
|
UI.user_error!("'#{value}' is not a valid 'status' value. Available options are #{available_options.join(', ')}") unless available_options.include?(value.to_s)
|
114
113
|
end,
|
115
|
-
|
114
|
+
type: Integer,
|
116
115
|
default_value: 2)
|
117
116
|
]
|
118
117
|
end
|
@@ -32,30 +32,25 @@ module Fastlane
|
|
32
32
|
env_name: "FL_TW_CONSUMER_KEY",
|
33
33
|
description: "Consumer Key",
|
34
34
|
sensitive: true,
|
35
|
-
is_string: true,
|
36
35
|
optional: false),
|
37
36
|
FastlaneCore::ConfigItem.new(key: :consumer_secret,
|
38
37
|
env_name: "FL_TW_CONSUMER_SECRET",
|
39
38
|
sensitive: true,
|
40
39
|
description: "Consumer Secret",
|
41
|
-
is_string: true,
|
42
40
|
optional: false),
|
43
41
|
FastlaneCore::ConfigItem.new(key: :access_token,
|
44
42
|
env_name: "FL_TW_ACCESS_TOKEN",
|
45
43
|
sensitive: true,
|
46
44
|
description: "Access Token",
|
47
|
-
is_string: true,
|
48
45
|
optional: false),
|
49
46
|
FastlaneCore::ConfigItem.new(key: :access_token_secret,
|
50
47
|
env_name: "FL_TW_ACCESS_TOKEN_SECRET",
|
51
48
|
sensitive: true,
|
52
49
|
description: "Access Token Secret",
|
53
|
-
is_string: true,
|
54
50
|
optional: false),
|
55
51
|
FastlaneCore::ConfigItem.new(key: :message,
|
56
52
|
env_name: "FL_TW_MESSAGE",
|
57
53
|
description: "The tweet",
|
58
|
-
is_string: true,
|
59
54
|
optional: false)
|
60
55
|
|
61
56
|
]
|
@@ -81,13 +81,13 @@ module Fastlane
|
|
81
81
|
optional: false),
|
82
82
|
FastlaneCore::ConfigItem.new(key: :add_to_search_list,
|
83
83
|
env_name: "FL_UNLOCK_KEYCHAIN_ADD_TO_SEARCH_LIST",
|
84
|
-
description: "Add to keychain search list",
|
85
|
-
|
84
|
+
description: "Add to keychain search list, valid values are true, false, :add, and :replace",
|
85
|
+
skip_type_validation: true, # allow Boolean, Symbol
|
86
86
|
default_value: true),
|
87
87
|
FastlaneCore::ConfigItem.new(key: :set_default,
|
88
88
|
env_name: "FL_UNLOCK_KEYCHAIN_SET_DEFAULT",
|
89
89
|
description: "Set as default keychain",
|
90
|
-
|
90
|
+
type: Boolean,
|
91
91
|
default_value: false)
|
92
92
|
|
93
93
|
]
|
@@ -53,10 +53,7 @@ module Fastlane
|
|
53
53
|
FastlaneCore::ConfigItem.new(key: :app_group_identifiers,
|
54
54
|
env_name: "FL_UPDATE_APP_GROUP_IDENTIFIER_APP_GROUP_IDENTIFIERS",
|
55
55
|
description: "An Array of unique identifiers for the app groups. Eg. ['group.com.test.testapp']",
|
56
|
-
|
57
|
-
verify_block: proc do |value|
|
58
|
-
UI.user_error!("The parameter app_group_identifiers need to be an Array.") unless value.kind_of?(Array)
|
59
|
-
end)
|
56
|
+
type: Array)
|
60
57
|
]
|
61
58
|
end
|
62
59
|
|
@@ -123,45 +123,38 @@ module Fastlane
|
|
123
123
|
FastlaneCore::ConfigItem.new(key: :use_automatic_signing,
|
124
124
|
env_name: "FL_PROJECT_USE_AUTOMATIC_SIGNING",
|
125
125
|
description: "Defines if project should use automatic signing",
|
126
|
-
|
126
|
+
type: Boolean,
|
127
127
|
default_value: false),
|
128
128
|
FastlaneCore::ConfigItem.new(key: :team_id,
|
129
129
|
env_name: "FASTLANE_TEAM_ID",
|
130
130
|
optional: true,
|
131
|
-
description: "Team ID, is used when upgrading project",
|
132
|
-
is_string: true),
|
131
|
+
description: "Team ID, is used when upgrading project"),
|
133
132
|
FastlaneCore::ConfigItem.new(key: :targets,
|
134
133
|
env_name: "FL_PROJECT_SIGNING_TARGETS",
|
135
134
|
optional: true,
|
136
135
|
type: Array,
|
137
|
-
description: "Specify targets you want to toggle the signing mech. (default to all targets)",
|
138
|
-
is_string: false),
|
136
|
+
description: "Specify targets you want to toggle the signing mech. (default to all targets)"),
|
139
137
|
FastlaneCore::ConfigItem.new(key: :build_configurations,
|
140
138
|
env_name: "FL_PROJECT_SIGNING_BUILD_CONFIGURATIONS",
|
141
139
|
optional: true,
|
142
140
|
type: Array,
|
143
|
-
description: "Specify build_configurations you want to toggle the signing mech. (default to all
|
144
|
-
is_string: false),
|
141
|
+
description: "Specify build_configurations you want to toggle the signing mech. (default to all configurations)"),
|
145
142
|
FastlaneCore::ConfigItem.new(key: :code_sign_identity,
|
146
143
|
env_name: "FL_CODE_SIGN_IDENTITY",
|
147
144
|
description: "Code signing identity type (iPhone Developer, iPhone Distribution)",
|
148
|
-
optional: true,
|
149
|
-
is_string: true),
|
145
|
+
optional: true),
|
150
146
|
FastlaneCore::ConfigItem.new(key: :profile_name,
|
151
147
|
env_name: "FL_PROVISIONING_PROFILE_SPECIFIER",
|
152
148
|
description: "Provisioning profile name to use for code signing",
|
153
|
-
optional: true,
|
154
|
-
is_string: true),
|
149
|
+
optional: true),
|
155
150
|
FastlaneCore::ConfigItem.new(key: :profile_uuid,
|
156
151
|
env_name: "FL_PROVISIONING_PROFILE",
|
157
152
|
description: "Provisioning profile UUID to use for code signing",
|
158
|
-
optional: true,
|
159
|
-
is_string: true),
|
153
|
+
optional: true),
|
160
154
|
FastlaneCore::ConfigItem.new(key: :bundle_identifier,
|
161
155
|
env_name: "FL_APP_IDENTIFIER",
|
162
156
|
description: "Application Product Bundle Identifier",
|
163
|
-
optional: true
|
164
|
-
is_string: true)
|
157
|
+
optional: true)
|
165
158
|
]
|
166
159
|
end
|
167
160
|
|
@@ -45,25 +45,36 @@ module Fastlane
|
|
45
45
|
end
|
46
46
|
|
47
47
|
# suppress updater output - very noisy
|
48
|
-
Gem::DefaultUserInteraction.ui = Gem::SilentUI.new
|
48
|
+
Gem::DefaultUserInteraction.ui = Gem::SilentUI.new unless FastlaneCore::Globals.verbose?
|
49
49
|
|
50
50
|
update_needed.each do |tool_info|
|
51
|
-
tool = tool_info
|
51
|
+
tool = self.get_gem_name(tool_info)
|
52
52
|
local_version = Gem::Version.new(highest_versions[tool].version)
|
53
53
|
latest_official_version = FastlaneCore::UpdateChecker.fetch_latest(tool)
|
54
54
|
|
55
55
|
UI.message("Updating #{tool} from #{local_version.to_s.yellow} to #{latest_official_version.to_s.yellow}... 🚀")
|
56
56
|
|
57
|
-
|
58
|
-
|
59
|
-
|
57
|
+
if Helper.homebrew?
|
58
|
+
Helper.backticks('brew upgrade fastlane')
|
59
|
+
else
|
60
|
+
# Approximate_recommendation will create a string like "~> 0.10" from a version 0.10.0, e.g. one that is valid for versions >= 0.10 and <1.0
|
61
|
+
requirement_version = local_version.approximate_recommendation
|
62
|
+
updater.update_gem(tool, Gem::Requirement.new(requirement_version))
|
63
|
+
end
|
60
64
|
|
61
65
|
UI.success("Finished updating #{tool}")
|
62
66
|
end
|
63
67
|
|
64
|
-
|
65
|
-
|
66
|
-
|
68
|
+
unless Helper.homebrew?
|
69
|
+
UI.message("Cleaning up old versions...")
|
70
|
+
cleaner.options[:args] = tools_to_update
|
71
|
+
cleaner.execute
|
72
|
+
end
|
73
|
+
|
74
|
+
if FastlaneCore::FastlaneFolder.swift?
|
75
|
+
upgrader = SwiftRunnerUpgrader.new
|
76
|
+
upgrader.upgrade_if_needed!
|
77
|
+
end
|
67
78
|
|
68
79
|
UI.message("fastlane.tools successfully updated! I will now restart myself... 😴")
|
69
80
|
|
@@ -71,6 +82,16 @@ module Fastlane
|
|
71
82
|
exec("FL_NO_UPDATE=true #{$PROGRAM_NAME} #{ARGV.join(' ')}")
|
72
83
|
end
|
73
84
|
|
85
|
+
def self.get_gem_name(tool_info)
|
86
|
+
if tool_info.kind_of?(Array)
|
87
|
+
return tool_info[0]
|
88
|
+
elsif tool_info.respond_to?(:name) # Gem::NameTuple in RubyGems >= 3.1.0
|
89
|
+
return tool_info.name
|
90
|
+
else
|
91
|
+
UI.crash!("Unknown gem update information returned from RubyGems. Please file a new issue for this... 🤷")
|
92
|
+
end
|
93
|
+
end
|
94
|
+
|
74
95
|
def self.description
|
75
96
|
"Makes sure fastlane-tools are up-to-date when running fastlane"
|
76
97
|
end
|
@@ -101,12 +122,12 @@ module Fastlane
|
|
101
122
|
FastlaneCore::ConfigItem.new(key: :no_update,
|
102
123
|
env_name: "FL_NO_UPDATE",
|
103
124
|
description: "Don't update during this run. This is used internally",
|
104
|
-
|
125
|
+
type: Boolean,
|
105
126
|
default_value: false),
|
106
127
|
FastlaneCore::ConfigItem.new(key: :nightly,
|
107
128
|
env_name: "FL_UPDATE_FASTLANE_NIGHTLY",
|
108
129
|
description: "Opt-in to install and use nightly fastlane builds",
|
109
|
-
|
130
|
+
type: Boolean,
|
110
131
|
default_value: false,
|
111
132
|
deprecated: "Nightly builds are no longer being made available")
|
112
133
|
]
|
@@ -61,10 +61,7 @@ module Fastlane
|
|
61
61
|
FastlaneCore::ConfigItem.new(key: :icloud_container_identifiers,
|
62
62
|
env_name: "FL_UPDATE_ICLOUD_CONTAINER_IDENTIFIERS_IDENTIFIERS",
|
63
63
|
description: "An Array of unique identifiers for the iCloud containers. Eg. ['iCloud.com.test.testapp']",
|
64
|
-
|
65
|
-
verify_block: proc do |value|
|
66
|
-
UI.user_error!("The parameter icloud_container_identifiers needs to be an Array.") unless value.kind_of?(Array)
|
67
|
-
end)
|
64
|
+
type: Array)
|
68
65
|
]
|
69
66
|
end
|
70
67
|
|
@@ -98,7 +98,7 @@ module Fastlane
|
|
98
98
|
description: 'The Display Name of your app',
|
99
99
|
optional: true),
|
100
100
|
FastlaneCore::ConfigItem.new(key: :block,
|
101
|
-
|
101
|
+
type: :string_callback,
|
102
102
|
description: 'A block to process plist with custom logic',
|
103
103
|
optional: true)
|
104
104
|
|
@@ -56,10 +56,7 @@ module Fastlane
|
|
56
56
|
FastlaneCore::ConfigItem.new(key: :identifiers,
|
57
57
|
env_name: "FL_UPDATE_KEYCHAIN_ACCESS_GROUPS_IDENTIFIERS",
|
58
58
|
description: "An Array of unique identifiers for the keychain access groups. Eg. ['your.keychain.access.groups.identifiers']",
|
59
|
-
|
60
|
-
verify_block: proc do |value|
|
61
|
-
UI.user_error!("The parameter identifiers need to be an Array.") unless value.kind_of?(Array)
|
62
|
-
end)
|
59
|
+
type: Array)
|
63
60
|
]
|
64
61
|
end
|
65
62
|
|
@@ -21,9 +21,8 @@ module Fastlane
|
|
21
21
|
# download certificate
|
22
22
|
unless File.exist?(params[:certificate])
|
23
23
|
UI.message("Downloading root certificate from (#{ROOT_CERTIFICATE_URL}) to path '#{params[:certificate]}'")
|
24
|
-
require 'open-uri'
|
25
24
|
File.open(params[:certificate], "w:ASCII-8BIT") do |file|
|
26
|
-
file.write(
|
25
|
+
file.write(FastlaneCore::Helper.open_uri(ROOT_CERTIFICATE_URL, "rb").read)
|
27
26
|
end
|
28
27
|
end
|
29
28
|
|
@@ -118,7 +117,7 @@ module Fastlane
|
|
118
117
|
env_name: "FL_PROJECT_PROVISIONING_PROFILE_TARGET_FILTER",
|
119
118
|
description: "A filter for the target name. Use a standard regex",
|
120
119
|
optional: true,
|
121
|
-
|
120
|
+
skip_type_validation: true, # allow Regexp, String
|
122
121
|
verify_block: proc do |value|
|
123
122
|
UI.user_error!("target_filter should be Regexp or String") unless [Regexp, String].any? { |type| value.kind_of?(type) }
|
124
123
|
end),
|
@@ -130,7 +129,7 @@ module Fastlane
|
|
130
129
|
env_name: "FL_PROJECT_PROVISIONING_PROFILE_BUILD_CONFIGURATION",
|
131
130
|
description: "A filter for the build configuration name. Use a standard regex. Applied to all configurations if not specified",
|
132
131
|
optional: true,
|
133
|
-
|
132
|
+
skip_type_validation: true, # allow Regexp, String
|
134
133
|
verify_block: proc do |value|
|
135
134
|
UI.user_error!("build_configuration should be Regexp or String") unless [Regexp, String].any? { |type| value.kind_of?(type) }
|
136
135
|
end),
|
@@ -58,7 +58,6 @@ module Fastlane
|
|
58
58
|
description: "The production app secret"),
|
59
59
|
FastlaneCore::ConfigItem.new(key: :detect_provisioning_mode,
|
60
60
|
env_name: "URBAN_AIRSHIP_DETECT_PROVISIONING_MODE",
|
61
|
-
is_string: false,
|
62
61
|
type: Boolean,
|
63
62
|
optional: true,
|
64
63
|
description: "Automatically detect provisioning mode")
|
@@ -51,33 +51,22 @@ module Fastlane
|
|
51
51
|
|
52
52
|
def self.available_options
|
53
53
|
[
|
54
|
-
FastlaneCore::ConfigItem.new(
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
key: :url_schemes,
|
67
|
-
env_name: "FL_UPDATE_URL_SCHEMES_SCHEMES",
|
68
|
-
description: 'The new URL schemes',
|
69
|
-
is_string: false,
|
70
|
-
optional: true,
|
71
|
-
verify_block: proc do |url_schemes|
|
72
|
-
string = "The URL schemes must be an array of strings, got '#{url_schemes}'."
|
73
|
-
verify_schemes!(url_schemes, string)
|
74
|
-
end
|
75
|
-
),
|
76
|
-
|
54
|
+
FastlaneCore::ConfigItem.new(key: :path,
|
55
|
+
env_name: 'FL_UPDATE_URL_SCHEMES_PATH',
|
56
|
+
description: 'The Plist file\'s path',
|
57
|
+
optional: false,
|
58
|
+
verify_block: proc do |path|
|
59
|
+
UI.user_error!("Could not find plist at path '#{path}'") unless File.exist?(path)
|
60
|
+
end),
|
61
|
+
FastlaneCore::ConfigItem.new(key: :url_schemes,
|
62
|
+
env_name: "FL_UPDATE_URL_SCHEMES_SCHEMES",
|
63
|
+
description: 'The new URL schemes',
|
64
|
+
type: Array,
|
65
|
+
optional: true),
|
77
66
|
FastlaneCore::ConfigItem.new(key: :update_url_schemes,
|
78
|
-
|
79
|
-
|
80
|
-
|
67
|
+
description: "Block that is called to update schemes with current schemes passed in as parameter",
|
68
|
+
optional: true,
|
69
|
+
type: :string_callback)
|
81
70
|
]
|
82
71
|
end
|
83
72
|
|
@@ -0,0 +1,290 @@
|
|
1
|
+
module Fastlane
|
2
|
+
module Actions
|
3
|
+
class UploadAppPrivacyDetailsToAppStoreAction < Action
|
4
|
+
DEFAULT_PATH = Fastlane::Helper.fastlane_enabled_folder_path
|
5
|
+
DEFAULT_FILE_NAME = "app_privacy_details.json"
|
6
|
+
|
7
|
+
def self.run(params)
|
8
|
+
require 'spaceship'
|
9
|
+
|
10
|
+
# Prompts select team if multiple teams and none specified
|
11
|
+
UI.message("Login to App Store Connect (#{params[:username]})")
|
12
|
+
Spaceship::ConnectAPI.login(params[:username], use_portal: false, use_tunes: true, tunes_team_id: params[:team_id], team_name: params[:team_name])
|
13
|
+
UI.message("Login successful")
|
14
|
+
|
15
|
+
# Get App
|
16
|
+
app = Spaceship::ConnectAPI::App.find(params[:app_identifier])
|
17
|
+
unless app
|
18
|
+
UI.user_error!("Could not find app with bundle identifier '#{params[:app_identifier]}' on account #{params[:username]}")
|
19
|
+
end
|
20
|
+
|
21
|
+
# Attempt to load JSON file
|
22
|
+
usages_config = load_json_file(params)
|
23
|
+
|
24
|
+
# Start interactive questions to generate and save JSON file
|
25
|
+
unless usages_config
|
26
|
+
usages_config = ask_interactive_questions_for_json
|
27
|
+
|
28
|
+
if params[:skip_json_file_saving]
|
29
|
+
UI.message("Skipping JSON file saving...")
|
30
|
+
else
|
31
|
+
json = JSON.pretty_generate(usages_config)
|
32
|
+
path = output_path(params)
|
33
|
+
|
34
|
+
UI.message("Writing file to #{path}")
|
35
|
+
File.write(path, json)
|
36
|
+
end
|
37
|
+
end
|
38
|
+
|
39
|
+
# Process JSON file to save app data usages to API
|
40
|
+
if params[:skip_upload]
|
41
|
+
UI.message("Skipping uploading of data... (so you can verify your JSON file)")
|
42
|
+
else
|
43
|
+
upload_app_data_usages(params, app, usages_config)
|
44
|
+
end
|
45
|
+
end
|
46
|
+
|
47
|
+
def self.load_json_file(params)
|
48
|
+
path = params[:json_path]
|
49
|
+
return nil if path.nil?
|
50
|
+
return JSON.parse(File.read(path))
|
51
|
+
end
|
52
|
+
|
53
|
+
def self.output_path(params)
|
54
|
+
path = params[:output_json_path]
|
55
|
+
return File.absolute_path(path)
|
56
|
+
end
|
57
|
+
|
58
|
+
def self.ask_interactive_questions_for_json(show_intro = true)
|
59
|
+
if show_intro
|
60
|
+
UI.important("You did not provide a JSON file for updating the app data usages")
|
61
|
+
UI.important("fastlane will now run you through interactive question to generate the JSON file")
|
62
|
+
UI.important("")
|
63
|
+
UI.important("This JSON file can be saved in source control and used in this action with the :json_file option")
|
64
|
+
|
65
|
+
unless UI.confirm("Ready to start?")
|
66
|
+
UI.user_error!("Cancelled")
|
67
|
+
end
|
68
|
+
end
|
69
|
+
|
70
|
+
# Fetch categories and purposes used for generating interactive questions
|
71
|
+
categories = Spaceship::ConnectAPI::AppDataUsageCategory.all(includes: "grouping")
|
72
|
+
purposes = Spaceship::ConnectAPI::AppDataUsagePurpose.all
|
73
|
+
|
74
|
+
json = []
|
75
|
+
|
76
|
+
unless UI.confirm("Are you collecting data?")
|
77
|
+
json << {
|
78
|
+
"data_protections" => [Spaceship::ConnectAPI::AppDataUsageDataProtection::ID::DATA_NOT_COLLECTED]
|
79
|
+
}
|
80
|
+
|
81
|
+
return json
|
82
|
+
end
|
83
|
+
|
84
|
+
categories.each do |category|
|
85
|
+
# Ask if using category
|
86
|
+
next unless UI.confirm("Collect data for #{category.id}?")
|
87
|
+
|
88
|
+
purpose_names = purposes.map(&:id).join(', ')
|
89
|
+
UI.message("How will this data be used? You'll be offered with #{purpose_names}")
|
90
|
+
|
91
|
+
# Ask purposes
|
92
|
+
selected_purposes = []
|
93
|
+
loop do
|
94
|
+
purposes.each do |purpose|
|
95
|
+
selected_purposes << purpose if UI.confirm("Used for #{purpose.id}?")
|
96
|
+
end
|
97
|
+
|
98
|
+
break unless selected_purposes.empty?
|
99
|
+
break unless UI.confirm("No purposes selected. Do you want to try again?")
|
100
|
+
end
|
101
|
+
|
102
|
+
# Skip asking protections if purposes were skipped
|
103
|
+
next if selected_purposes.empty?
|
104
|
+
|
105
|
+
# Ask protections
|
106
|
+
is_linked_to_user = UI.confirm("Is #{category.id} linked to the user?")
|
107
|
+
is_used_for_tracking = UI.confirm("Is #{category.id} used for tracking purposes?")
|
108
|
+
|
109
|
+
# Map answers to values for API requests
|
110
|
+
protection_id = is_linked_to_user ? Spaceship::ConnectAPI::AppDataUsageDataProtection::ID::DATA_LINKED_TO_YOU : Spaceship::ConnectAPI::AppDataUsageDataProtection::ID::DATA_NOT_LINKED_TO_YOU
|
111
|
+
tracking_id = is_used_for_tracking ? Spaceship::ConnectAPI::AppDataUsageDataProtection::ID::DATA_USED_TO_TRACK_YOU : nil
|
112
|
+
|
113
|
+
json << {
|
114
|
+
"category" => category.id,
|
115
|
+
"purposes" => selected_purposes.map(&:id).sort.uniq,
|
116
|
+
"data_protections" => [
|
117
|
+
protection_id, tracking_id
|
118
|
+
].compact.sort.uniq
|
119
|
+
}
|
120
|
+
end
|
121
|
+
|
122
|
+
json.sort_by! { |c| c["category"] }
|
123
|
+
|
124
|
+
# Recursively call this method if no categories were selected for data collection
|
125
|
+
if json.empty?
|
126
|
+
UI.error("No categories were selected for data collection.")
|
127
|
+
json = ask_interactive_questions_for_json(false)
|
128
|
+
end
|
129
|
+
|
130
|
+
return json
|
131
|
+
end
|
132
|
+
|
133
|
+
def self.upload_app_data_usages(params, app, usages_config)
|
134
|
+
UI.message("Preparing to upload App Data Usage")
|
135
|
+
|
136
|
+
# Delete all existing usages for new ones
|
137
|
+
all_usages = Spaceship::ConnectAPI::AppDataUsage.all(app_id: app.id, includes: "category,grouping,purpose,dataProtection", limit: 500)
|
138
|
+
all_usages.each(&:delete!)
|
139
|
+
|
140
|
+
usages_config.each do |usage_config|
|
141
|
+
category = usage_config["category"]
|
142
|
+
purposes = usage_config["purposes"] || []
|
143
|
+
data_protections = usage_config["data_protections"] || []
|
144
|
+
|
145
|
+
# There will not be any purposes if "not collecting data"
|
146
|
+
# However, an AppDataUsage still needs to be created for not collecting data
|
147
|
+
# Creating an array with nil so that purposes can be iterated over and
|
148
|
+
# that AppDataUsage can be created
|
149
|
+
purposes = [nil] if purposes.empty?
|
150
|
+
|
151
|
+
purposes.each do |purpose|
|
152
|
+
data_protections.each do |data_protection|
|
153
|
+
if data_protection == Spaceship::ConnectAPI::AppDataUsageDataProtection::ID::DATA_NOT_COLLECTED
|
154
|
+
UI.message("Setting #{data_protection}")
|
155
|
+
else
|
156
|
+
UI.message("Setting #{category} and #{purpose} to #{data_protection}")
|
157
|
+
end
|
158
|
+
|
159
|
+
Spaceship::ConnectAPI::AppDataUsage.create(
|
160
|
+
app_id: app.id,
|
161
|
+
app_data_usage_category_id: category,
|
162
|
+
app_data_usage_protection_id: data_protection,
|
163
|
+
app_data_usage_purpose_id: purpose
|
164
|
+
)
|
165
|
+
end
|
166
|
+
end
|
167
|
+
end
|
168
|
+
|
169
|
+
# Publish
|
170
|
+
if params[:skip_publish]
|
171
|
+
UI.message("Skipping app data usage publishing... (so you can verify on App Store Connect)")
|
172
|
+
else
|
173
|
+
publish_state = Spaceship::ConnectAPI::AppDataUsagesPublishState.get(app_id: app.id)
|
174
|
+
if publish_state.published
|
175
|
+
UI.important("App data usage is already published")
|
176
|
+
else
|
177
|
+
UI.important("App data usage not published! Going to publish...")
|
178
|
+
publish_state.publish!
|
179
|
+
UI.important("App data usage is now published")
|
180
|
+
end
|
181
|
+
end
|
182
|
+
end
|
183
|
+
|
184
|
+
def self.description
|
185
|
+
"Upload App Privacy Details for an app in App Store Connect"
|
186
|
+
end
|
187
|
+
|
188
|
+
def self.available_options
|
189
|
+
user = CredentialsManager::AppfileConfig.try_fetch_value(:itunes_connect_id)
|
190
|
+
user ||= CredentialsManager::AppfileConfig.try_fetch_value(:apple_id)
|
191
|
+
|
192
|
+
[
|
193
|
+
FastlaneCore::ConfigItem.new(key: :username,
|
194
|
+
env_name: "FASTLANE_USER",
|
195
|
+
description: "Your Apple ID Username for App Store Connect",
|
196
|
+
default_value: user,
|
197
|
+
default_value_dynamic: true),
|
198
|
+
FastlaneCore::ConfigItem.new(key: :app_identifier,
|
199
|
+
env_name: "UPLOAD_APP_PRIVACY_DETAILS_TO_APP_STORE_APP_IDENTIFIER",
|
200
|
+
description: "The bundle identifier of your app",
|
201
|
+
code_gen_sensitive: true,
|
202
|
+
default_value: CredentialsManager::AppfileConfig.try_fetch_value(:app_identifier),
|
203
|
+
default_value_dynamic: true),
|
204
|
+
FastlaneCore::ConfigItem.new(key: :team_id,
|
205
|
+
env_name: "FASTLANE_ITC_TEAM_ID",
|
206
|
+
description: "The ID of your App Store Connect team if you're in multiple teams",
|
207
|
+
optional: true,
|
208
|
+
skip_type_validation: true, # as we also allow integers, which we convert to strings anyway
|
209
|
+
code_gen_sensitive: true,
|
210
|
+
default_value: CredentialsManager::AppfileConfig.try_fetch_value(:itc_team_id),
|
211
|
+
default_value_dynamic: true),
|
212
|
+
FastlaneCore::ConfigItem.new(key: :team_name,
|
213
|
+
env_name: "FASTLANE_ITC_TEAM_NAME",
|
214
|
+
description: "The name of your App Store Connect team if you're in multiple teams",
|
215
|
+
optional: true,
|
216
|
+
code_gen_sensitive: true,
|
217
|
+
default_value: CredentialsManager::AppfileConfig.try_fetch_value(:itc_team_name),
|
218
|
+
default_value_dynamic: true),
|
219
|
+
|
220
|
+
# JSON paths
|
221
|
+
FastlaneCore::ConfigItem.new(key: :json_path,
|
222
|
+
env_name: "UPLOAD_APP_PRIVACY_DETAILS_TO_APP_STORE_JSON_PATH",
|
223
|
+
description: "Path to the app usage data JSON",
|
224
|
+
optional: true,
|
225
|
+
verify_block: proc do |value|
|
226
|
+
UI.user_error!("Could not find JSON file at path '#{File.expand_path(value)}'") unless File.exist?(value)
|
227
|
+
UI.user_error!("'#{value}' doesn't seem to be a JSON file") unless FastlaneCore::Helper.json_file?(File.expand_path(value))
|
228
|
+
end),
|
229
|
+
FastlaneCore::ConfigItem.new(key: :output_json_path,
|
230
|
+
env_name: "UPLOAD_APP_PRIVACY_DETAILS_TO_APP_STORE_OUTPUT_JSON_PATH",
|
231
|
+
description: "Path to the app usage data JSON file generated by interactive questions",
|
232
|
+
conflicting_options: [:skip_json_file_saving],
|
233
|
+
default_value: File.join(DEFAULT_PATH, DEFAULT_FILE_NAME)),
|
234
|
+
|
235
|
+
# Skipping options
|
236
|
+
FastlaneCore::ConfigItem.new(key: :skip_json_file_saving,
|
237
|
+
env_name: "UPLOAD_APP_PRIVACY_DETAILS_TO_APP_STORE_OUTPUT_SKIP_JSON_FILE_SAVING",
|
238
|
+
description: "Whether to skip the saving of the JSON file",
|
239
|
+
conflicting_options: [:skip_output_json_path],
|
240
|
+
type: Boolean,
|
241
|
+
default_value: false),
|
242
|
+
FastlaneCore::ConfigItem.new(key: :skip_upload,
|
243
|
+
env_name: "UPLOAD_APP_PRIVACY_DETAILS_TO_APP_STORE_OUTPUT_SKIP_UPLOAD",
|
244
|
+
description: "Whether to skip the upload and only create the JSON file with interactive questions",
|
245
|
+
conflicting_options: [:skip_publish],
|
246
|
+
type: Boolean,
|
247
|
+
default_value: false),
|
248
|
+
FastlaneCore::ConfigItem.new(key: :skip_publish,
|
249
|
+
env_name: "UPLOAD_APP_PRIVACY_DETAILS_TO_APP_STORE_OUTPUT_SKIP_PUBLISH",
|
250
|
+
description: "Whether to skip the publishing",
|
251
|
+
conflicting_options: [:skip_upload],
|
252
|
+
type: Boolean,
|
253
|
+
default_value: false)
|
254
|
+
]
|
255
|
+
end
|
256
|
+
|
257
|
+
def self.author
|
258
|
+
"joshdholtz"
|
259
|
+
end
|
260
|
+
|
261
|
+
def self.is_supported?(platform)
|
262
|
+
[:ios, :mac, :tvos].include?(platform)
|
263
|
+
end
|
264
|
+
|
265
|
+
def self.details
|
266
|
+
"Upload App Privacy Details for an app in App Store Connect. For more detail information, view https://docs.fastlane.tools/uploading-app-privacy-details"
|
267
|
+
end
|
268
|
+
|
269
|
+
def self.example_code
|
270
|
+
[
|
271
|
+
'upload_app_privacy_details_to_app_store(
|
272
|
+
username: "your@email.com",
|
273
|
+
team_name: "Your Team",
|
274
|
+
app_identifier: "com.your.bundle"
|
275
|
+
)',
|
276
|
+
'upload_app_privacy_details_to_app_store(
|
277
|
+
username: "your@email.com",
|
278
|
+
team_name: "Your Team",
|
279
|
+
app_identifier: "com.your.bundle",
|
280
|
+
json_path: "fastlane/app_data_usages.json"
|
281
|
+
)'
|
282
|
+
]
|
283
|
+
end
|
284
|
+
|
285
|
+
def self.category
|
286
|
+
:production
|
287
|
+
end
|
288
|
+
end
|
289
|
+
end
|
290
|
+
end
|