Skip to content

Instantly share code, notes, and snippets.

View jobearrr's full-sized avatar
:octocat:

Jobert Sá jobearrr

:octocat:
View GitHub Profile
@jobearrr
jobearrr / xcode_version_increment.sh
Last active February 2, 2021 10:46
Increment version numbers on Xcode
# This came out of an answer I gave on stackoverflow:
# https://stackoverflow.com/questions/66006333/auto-increment-version-number-in-ios-application-using-azure-devops/66007332#66007332
# This script will increment the version numbers each time it's executed:
# 0.0.1 -> 0.0.2 -> ... -> 0.0.99 -> 0.1.0 -> 0.1.1 -> 0.1.2 -> ... -> 0.1.99 -> 0.2.0 -> ... -> 0.99.99 -> 1.0.0
#
# It can be easily adapted to follow other rules.
# And it can also be integrated as a build a build phase in a Xcode project.
buildPlist="Info.plist" # Enter the path to your plist file here
maxSubversionNumber=99 # Set what will be the maximum number to increment each sub version to