fastlane: `increment_version_number` fails to update `MARKETING_VERSION`

New Issue Checklist

Issue Description

When you specify the version number for an application in XCode, it sets a variable MARKETING_VERSION in the project, and makes a reference to this variable in the Info.plist.

However, if you want to manage this version automatically using increment_version_number, you get get the error Your current version ($(MARKETING_VERSION)) does not respect the format A or A.B or A.B.C.

Command executed

incremement_version_number

Complete output when running fastlane, including the stack trace and command used
 [20:25:21]: ----------------------------------------
[20:25:21]: --- Step: Verifying fastlane version ---
[20:25:21]: ----------------------------------------
[20:25:21]: Your fastlane version 2.205.1 matches the minimum requirement of 2.205.1  ✅
[20:25:21]: --------------------------------
[20:25:21]: --- Step: get_version_number ---
[20:25:21]: --------------------------------
[20:25:21]: Driving the lane 'ios bumpPatch' 🚀
[20:25:21]: --------------------------------------
[20:25:21]: --- Step: Switch to ios setup lane ---
[20:25:21]: --------------------------------------
[20:25:21]: Cruising over to lane 'ios setup' 🚖
[20:25:21]: -----------------------
[20:25:21]: --- Step: yarn sync ---
[20:25:21]: -----------------------
[20:25:21]: <REDACTED>

[20:25:27]: Cruising back to lane ‘ios bumpPatch’ 🚘 [20:25:27]: -------------------------------------- [20:25:27]: — Step: increment_version_number — [20:25:27]: -------------------------------------- [20:25:28]: Before being able to increment and read the version number from your Xcode project, you first need to setup your project properly. Please follow the guide at https://developer.apple.com/library/content/qa/qa1827/_index.html ±---------------±--------------+ | Lane Context | ±---------------±--------------+ | VERSION_NUMBER | 0.1.0 | | PLATFORM_NAME | ios | | LANE_NAME | ios bumpPatch | ±---------------±--------------+ [20:25:28]: Your current version ($(MARKETING_VERSION)) does not respect the format A or A.B or A.B.C

±-----±---------------------------±------------+ | fastlane summary | ±-----±---------------------------±------------+ | Step | Action | Time (in s) | ±-----±---------------------------±------------+ | 1 | Verifying fastlane version | 0 | | 2 | get_version_number | 0 | | 3 | Switch to ios setup lane | 0 | | 4 | yarn sync | 6 | | 💥 | increment_version_number | 1 | ±-----±---------------------------±------------+

[20:25:28]: fastlane finished with errors

[!] Your current version ($(MARKETING_VERSION)) does not respect the format A or A.B or A.B.C

Environment

 
✅ fastlane environment ✅

Stack

Key Value
OS 12.3
Ruby 3.0.1
Bundler? true
Git git version 2.35.1
Installation Source ~/.rvm/gems/ruby-3.0.1/bin/fastlane
Host macOS 12.3 (21E230)
Ruby Lib Dir ~/.rvm/rubies/ruby-3.0.1/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/Xcode.app/Contents/Developer/
Xcode Version 13.3
Swift Version 5.6

System Locale

Variable Value
LANG en_GB.UTF-8
LC_ALL
LANGUAGE

fastlane files:

** Fastfile Redacted** No Appfile found

fastlane gems

Gem Version Update-Status
fastlane 2.205.1 ✅ Up-To-Date

Loaded fastlane plugins:

No plugins Loaded

Loaded gems
Gem Version
did_you_mean 1.5.0
bundler 2.3.10
tsort 0.1.0
uri 0.10.1
pathname 0.1.0
rake 13.0.6
rexml 3.2.5
CFPropertyList 3.0.5
concurrent-ruby 1.1.10
i18n 1.10.0
minitest 5.15.0
tzinfo 2.0.4
zeitwerk 2.5.4
activesupport 6.1.5
public_suffix 4.0.6
addressable 2.8.0
httpclient 2.8.3
json 2.6.1
algoliasearch 1.27.5
artifactory 3.0.15
atomos 0.1.3
aws-eventstream 1.2.0
aws-partitions 1.571.0
aws-sigv4 1.4.0
jmespath 1.6.1
aws-sdk-core 3.130.0
aws-sdk-kms 1.55.0
aws-sdk-s3 1.113.0
babosa 1.0.4
claide 1.1.0
fuzzy_match 2.0.4
nap 1.1.0
netrc 0.11.0
ffi 1.15.5
ethon 0.15.0
typhoeus 1.4.0
cocoapods-core 1.11.3
cocoapods-deintegrate 1.0.5
cocoapods-downloader 1.6.2
cocoapods-plugins 1.0.0
cocoapods-search 1.0.1
cocoapods-trunk 1.6.0
cocoapods-try 1.2.0
colored2 3.1.2
escape 0.0.4
fourflusher 2.3.1
gh_inspector 1.1.3
molinillo 0.8.0
ruby-macho 2.5.1
nanaimo 0.3.0
xcodeproj 1.21.0
cocoapods 1.11.3
colored 1.2
highline 2.0.3
commander 4.6.0
declarative 0.0.20
digest-crc 0.6.4
unf_ext 0.0.8.1
unf 0.1.4
domain_name 0.5.20190701
dotenv 2.7.6
emoji_regex 3.2.3
excon 0.92.1
faraday-em_http 1.0.0
faraday-em_synchrony 1.0.0
faraday-excon 1.1.0
faraday-httpclient 1.0.1
multipart-post 2.0.0
faraday-multipart 1.0.3
faraday-net_http 1.0.1
faraday-net_http_persistent 1.2.0
faraday-patron 1.0.0
faraday-rack 1.0.0
faraday-retry 1.0.3
ruby2_keywords 0.0.5
faraday 1.10.0
http-cookie 1.0.4
faraday-cookie_jar 0.0.7
faraday_middleware 1.2.0
fastimage 2.2.6
jwt 2.3.0
memoist 0.16.2
multi_json 1.15.0
os 1.1.4
signet 0.16.1
googleauth 1.1.2
mini_mime 1.1.2
trailblazer-option 0.1.2
uber 0.1.0
representable 3.1.1
retriable 3.1.2
webrick 1.7.0
google-apis-core 0.4.2
google-apis-androidpublisher_v3 0.17.0
google-apis-playcustomapp_v1 0.7.0
google-apis-iamcredentials_v1 0.10.0
google-apis-storage_v1 0.11.0
google-cloud-env 1.6.0
google-cloud-errors 1.2.0
google-cloud-core 1.6.0
google-cloud-storage 1.36.1
mini_magick 4.11.0
naturally 2.2.1
optparse 0.1.1
plist 3.6.0
rubyzip 2.3.2
security 0.1.3
simctl 1.6.8
terminal-notifier 2.0.0
unicode-display_width 1.8.0
terminal-table 1.8.0
tty-screen 0.8.1
tty-cursor 0.7.1
tty-spinner 0.9.3
word_wrap 1.0.0
rouge 2.0.7
xcpretty 0.3.0
xcpretty-travis-formatter 1.0.1

generated on: 2022-03-29

About this issue

  • Original URL
  • State: open
  • Created 2 years ago
  • Reactions: 2
  • Comments: 21

Commits related to this issue

Most upvoted comments

+1 to keep it going.

Any solution ??

One possible solution is to use plugin Versioning