Closed sidneivl closed 2 years ago
I got one error:
Cannot set build number with plist path containing $(SRCROOT) Please remove $(SRCROOT) in your Xcode target build settings
I've deleted $(SRCROOT), not get error anymore, but when upload to Test Flight, fastlane still increment the build number instead to get number setted by me.
There hasn't been any activity on this issue recently. Due to the high number of incoming GitHub notifications, we have to clean some of the old issues, as many of them have already been resolved with the latest updates.
Please make sure to update to the latest fastlane
version and check if that solves the issue. Let us know if that works for you by adding a comment :+1:
Friendly reminder: contributions are always welcome! Check out CONTRIBUTING.md for more information on how to help with fastlane
and feel free to tackle this issue yourself :muscle:
This issue will be auto-closed if there is no reply within 1 month.
This issue will be auto-closed because there hasn't been any activity for a few months. Feel free to open a new one if you still experience this problem :+1:
New Issue Checklist
Issue Description
Fastlane not getting CURRENT_PROJECT_VERSION, just do increment build version on Test Flight Before to update to xcode 13 I ran the command 'bundle exec fastlane beta skiptest:true' and when upload to Test Flight I saw a build with build ID and now I got just an incrementation of build.
Complete output when running fastlane, including the stack trace and command used
+------+---------------------------------------+-------------+ | fastlane summary | +------+---------------------------------------+-------------+ | Step | Action | Time (in s) | +------+---------------------------------------+-------------+ | 1 | default_platform | 0 | | 2 | clear_derived_data | 3 | | 3 | sync_code_signing | 12 | | 4 | build_app | 242 | | 5 | upload_symbols_to_crashlytics | 0 | | 6 | upload_to_testflight | 99 | | 7 | get_version_number | 0 | | 8 | get_build_number_from_plist | 0 | | 9 | Switch to ios notification_slack lane | 0 | | 10 | slack | 0 | +------+---------------------------------------+-------------+
Environment
🚫 fastlane environment 🚫
### Stack | Key | Value | | --------------------------- | --------------------------------------------- | | OS | 12.0.1 | | Ruby | 3.0.2 | | Bundler? | false | | Git | git version 2.30.1 (Apple Git-130) | | Installation Source | ~/.rbenv/versions/3.0.2/bin/fastlane | | Host | macOS 12.0.1 (21A559) | | Ruby Lib Dir | ~/.rbenv/versions/3.0.2/lib | | OpenSSL Version | OpenSSL 1.1.1k 25 Mar 2021 | | Is contained | false | | Is homebrew | false | | Is installed via Fabric.app | false | | Xcode Path | /Applications/Xcode13.app/Contents/Developer/ | | Xcode Version | 13.1 | | Swift Version | 5.5.1 | ### System Locale | Error | | --------------------------- | | No Locale with UTF8 found 🚫 | ### fastlane files:`./fastlane/Fastfile`
```ruby default_platform(:ios) #config appname_dev = "GloboMais ONE DEV" appname_prod = "GloboMais ONE" target_dev = "develop" target_prod = "release" workspace = "GloboMais.xcworkspace" project = "app-globo-mais-one-ios.xcodeproj" device = "iPhone X" build_by = "Fastlane" build_type_beta_dev = "DEV - Beta" build_type_beta_prod = "PROD - Beta" build_type_release_prod = "PROD - Release" dSYM_dev = "./GloboMais.app.dSYM.zip" dSYM_prod = "./GloboMais.app.dSYM.zip" slack_channel = "#ios_build" slack_url = "https://hooks.slack.com/services/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" slack_message = "App successfully added on itunes connect!" platform :ios do desc "Check code style" lane :lint_code do swiftlint( mode: :lint, config_file: ".swiftlint.yml" ) end desc "Create coverage report" lane :coverage do slather( html: true, show: true, output_directory: 'fastlane/slather', scheme: target_dev, workspace: workspace, proj: project) end desc "Used by Development to keep code quality. Use command: 'fastlane check_code dev:true'" lane :check_code do |options| lint_code # if options[:dev] # just when use tests scan( code_coverage: true, scheme: target_dev, clean: true, devices: [device] ) coverage # else # just when use tests # scan(code_coverage: true, # scheme: target_prod) # end end desc "Documentation using Jazzy" lane :documentation do jazzy(config: '.jazzy.yaml') git_add(path: "./docs/*", shell_escape: false) git_commit(path: "./docs/*", message: "Update doc with jazzy and fastlane") push_to_git_remote end desc "Notification to slack" private_lane :notification_slack do |options| slack( message: slack_message, channel: slack_channel, # Optional, by default will post to the default channel configured for the POST URL. success: true, # Optional, defaults to true. slack_url: slack_url, payload: { # Optional, lets you specify any number of your own Slack attachments. "App Name" => options[:app_name], "Version Number" => options[:verion], "Build Type" => options[:build_type], "Build Number" => options[:build], "Build Date" => Time.new.to_s, "Built by" => options[:build_by] } ) end desc "Notification error to slack" private_lane :notification_slack_error do |options| slack( message: options[:exception], channel: slack_channel, # Optional, by default will post to the default channel configured for the POST URL. success: false, # Optional, defaults to true. slack_url: slack_url, payload: { # Optional, lets you specify any number of your own Slack attachments. "Lane" => options[:lane], "Output" => options[:exception_output] } ) end desc "Carthage update" private_lane :carthage_update do |options| carthage( command: "update", # One of: build, bootstrap, update, archive. (default: bootstrap) no_skip_current: false, # Don't skip building the current project (only for frameworks) platform: "iOS", # Define which platform to build for (one of ‘all’, ‘Mac’, ‘iOS’, ‘watchOS’, ‘tvOS‘, or comma-separated values of the formers except for ‘all’) cache_builds: true, # By default Carthage will rebuild a dependency regardless of whether its the same resolved version as before. use_binaries: true, # Check out dependency repositories even when prebuilt frameworks exist log_path: "carthage.log" # Path to the xcode build output ) end desc "upload to QA, to use DEV version just use the command 'fastlane beta dev:true', if you want skip test use the command fastlane beta skiptest:true" lane :beta do |options| clear_derived_data # carthage_update if !options[:skiptest] check_code end sync_code_signing(type: "appstore") app_target = target_prod app_dSYM = dSYM_prod app_name = appname_prod app_build_type = build_type_beta_prod if options[:dev] app_target = target_dev app_dSYM = dSYM_dev app_name = appname_dev app_build_type = build_type_beta_dev end build_app(scheme: app_target) upload_symbols_to_crashlytics(binary_path: "./", dsym_path: app_dSYM) upload_to_testflight(skip_waiting_for_build_processing: true) notification_slack(app_name: app_name, verion: get_version_number( xcodeproj: project, target: "AppGloboMaisOneIos"), build: get_build_number_from_plist(xcodeproj: project, # optional target: "AppGloboMaisOneIos", plist_build_setting_support: true), build_by: build_by, build_type: app_build_type) end desc "upload to store" lane :release do check_code carthage_update sync_code_signing(type: "appstore") build_app(scheme: target_prod) upload_symbols_to_crashlytics(binary_path: "./", dsym_path: dSYM_prod) upload_to_app_store(submit_for_review: false, automatic_release: false, force: true, # Skip HTMl report verification skip_metadata: true, skip_screenshots: true) documentation notification_slack(app_name: appname_prod, verion: get_version_number( xcodeproj: project, target: "AppGloboMaisOneIos"), build: get_build_number_from_plist(xcodeproj: project, # optional target: "AppGloboMaisOneIos", plist_build_setting_support: true), build_by: build_by, build_type: build_type_release_prod) end error do |lane, exception| notification_slack_error( lane: lane.to_s, exception: exception.to_s, exception_output: exception.error_info.to_s) end end ````./fastlane/Appfile`
```ruby # app_identifier("[[APP_IDENTIFIER]]") # The bundle identifier of your app apple_id ENV['APPLE_ID'] # Your Apple email address team_id "29MQPP6L4J" itc_team_id "371111" # For more information about the Appfile, see: # https://docs.fastlane.tools/advanced/#appfile ```Loaded gems
| Gem | Version | | ------------------------------- | ------------ | | did_you_mean | 1.5.0 | | rouge | 2.0.7 | | xcpretty | 0.3.0 | | terminal-notifier | 2.0.0 | | terminal-table | 1.8.0 | | plist | 3.6.0 | | public_suffix | 4.0.6 | | addressable | 2.8.0 | | multipart-post | 2.0.0 | | word_wrap | 1.0.0 | | optparse | 0.1.1 | | tty-screen | 0.8.1 | | tty-cursor | 0.7.1 | | tty-spinner | 0.9.3 | | artifactory | 3.0.15 | | babosa | 1.0.4 | | colored | 1.2 | | highline | 2.0.3 | | commander | 4.6.0 | | unf | 0.1.4 | | domain_name | 0.5.20190701 | | http-cookie | 1.0.4 | | faraday-cookie_jar | 0.0.7 | | gh_inspector | 1.1.3 | | mini_magick | 4.11.0 | | naturally | 2.2.1 | | rubyzip | 2.3.2 | | security | 0.1.3 | | xcpretty-travis-formatter | 1.0.1 | | dotenv | 2.7.6 | | bundler | 2.2.22 | | simctl | 1.6.8 | | uber | 0.1.0 | | declarative | 0.0.20 | | trailblazer-option | 0.1.1 | | representable | 3.1.1 | | retriable | 3.1.2 | | httpclient | 2.8.3 | | rexml | 3.2.5 | | webrick | 1.7.0 | | google-apis-core | 0.4.1 | | google-apis-playcustomapp_v1 | 0.5.0 | | google-cloud-env | 1.5.0 | | google-cloud-core | 1.6.0 | | google-cloud-storage | 1.34.1 | | tsort | 0.1.0 | | uri | 0.10.1 | | set | 1.0.1 | | nanaimo | 0.3.0 | | colored2 | 3.1.2 | | claide | 1.0.3 | | CFPropertyList | 3.0.4 | | atomos | 0.1.3 | | xcodeproj | 1.21.0 | | unicode-display_width | 1.8.0 | | excon | 0.87.0 | | ruby2_keywords | 0.0.5 | | faraday-rack | 1.0.0 | | faraday-patron | 1.0.0 | | faraday-net_http_persistent | 1.2.0 | | faraday-net_http | 1.0.1 | | faraday-httpclient | 1.0.1 | | faraday-excon | 1.1.0 | | faraday-em_synchrony | 1.0.0 | | faraday-em_http | 1.0.0 | | faraday | 1.8.0 | | unf_ext | 0.0.8 | | faraday_middleware | 1.2.0 | | fastimage | 2.2.5 | | json | 2.6.1 | | jwt | 2.3.0 | | mini_mime | 1.1.2 | | multi_json | 1.15.0 | | signet | 0.16.0 | | os | 1.1.1 | | memoist | 0.16.2 | | googleauth | 1.1.0 | | google-apis-androidpublisher_v3 | 0.12.0 | | google-cloud-errors | 1.2.0 | | google-apis-iamcredentials_v1 | 0.7.0 | | google-apis-storage_v1 | 0.8.0 | | rake | 13.0.6 | | digest-crc | 0.6.4 | | emoji_regex | 3.2.3 | | aws-eventstream | 1.2.0 | | aws-sigv4 | 1.4.0 | | aws-partitions | 1.519.0 | | jmespath | 1.4.0 | | aws-sdk-core | 3.121.3 | | aws-sdk-kms | 1.50.0 | | aws-sdk-s3 | 1.104.0 | | forwardable | 1.3.2 | | logger | 1.4.3 | | pathname | 0.1.0 | | shellwords | 0.1.0 | | cgi | 0.2.0 | | date | 3.1.0 | | timeout | 0.1.1 | | stringio | 3.0.0 | | openssl | 2.2.0 | | io-nonblock | 0.1.0 | | ipaddr | 1.2.2 | | io-wait | 0.1.0 | | zlib | 1.1.0 | | resolv | 0.2.0 | | securerandom | 0.1.0 | | digest | 3.0.0 | | time | 0.1.0 | | open-uri | 0.1.0 | | mutex_m | 0.1.1 | | net-protocol | 0.1.0 | | ostruct | 0.3.1 | | english | 0.7.1 | | erb | 2.2.0 | | strscan | 3.0.0 | | abbrev | 0.1.0 | | io-console | 0.5.7 | | tempfile | 0.1.1 | | delegate | 0.2.0 | | fileutils | 1.5.0 | | tmpdir | 0.1.2 | | base64 | 0.1.0 | | singleton | 0.1.1 | | net-http | 0.1.1 | | open3 | 0.1.1 | | nkf | 0.1.0 | | nokogiri | 1.12.3 | | racc | 1.5.2 | | prettyprint | 0.1.0 | | pp | 0.1.0 | | find | 0.1.0 | | yaml | 0.1.1 | | psych | 3.3.0 | | fastlane-plugin-versioning | 0.5.0 |