mirror of
https://github.com/Novaloop-AG/element-x-ios.git
synced 2026-10-31 16:24:11 +00:00
Release script fixes: prevent sed from incorrectly matching other versions, correctly increment the path version past .9 which would previously increment the minor
This commit is contained in:
committed by
Stefan Ceriu
parent
c5c8715e07
commit
612a28b7e2
@@ -7,6 +7,7 @@ source "https://rubygems.org"
|
|||||||
gem 'fastlane'
|
gem 'fastlane'
|
||||||
gem "xcode-install"
|
gem "xcode-install"
|
||||||
gem 'slather'
|
gem 'slather'
|
||||||
|
gem 'semantic'
|
||||||
|
|
||||||
plugins_path = File.join(File.dirname(__FILE__), 'fastlane', 'Pluginfile')
|
plugins_path = File.join(File.dirname(__FILE__), 'fastlane', 'Pluginfile')
|
||||||
eval_gemfile('fastlane/Pluginfile') if File.exist?(plugins_path)
|
eval_gemfile('fastlane/Pluginfile') if File.exist?(plugins_path)
|
||||||
|
|||||||
@@ -210,6 +210,7 @@ GEM
|
|||||||
ruby2_keywords (0.0.5)
|
ruby2_keywords (0.0.5)
|
||||||
rubyzip (2.3.2)
|
rubyzip (2.3.2)
|
||||||
security (0.1.3)
|
security (0.1.3)
|
||||||
|
semantic (1.6.1)
|
||||||
signet (0.17.0)
|
signet (0.17.0)
|
||||||
addressable (~> 2.8)
|
addressable (~> 2.8)
|
||||||
faraday (>= 0.17.5, < 3.a)
|
faraday (>= 0.17.5, < 3.a)
|
||||||
@@ -266,6 +267,7 @@ DEPENDENCIES
|
|||||||
fastlane-plugin-sentry
|
fastlane-plugin-sentry
|
||||||
fastlane-plugin-xcconfig
|
fastlane-plugin-xcconfig
|
||||||
fastlane-plugin-xcodegen
|
fastlane-plugin-xcodegen
|
||||||
|
semantic
|
||||||
slather
|
slather
|
||||||
xcode-install
|
xcode-install
|
||||||
|
|
||||||
|
|||||||
+6
-2
@@ -1,4 +1,5 @@
|
|||||||
require 'yaml'
|
require 'yaml'
|
||||||
|
require 'semantic'
|
||||||
require_relative 'changelog'
|
require_relative 'changelog'
|
||||||
|
|
||||||
before_all do
|
before_all do
|
||||||
@@ -256,11 +257,14 @@ lane :prepare_next_release do
|
|||||||
|
|
||||||
data = YAML.load_file target_file_path
|
data = YAML.load_file target_file_path
|
||||||
current_version = data["settings"]["MARKETING_VERSION"]
|
current_version = data["settings"]["MARKETING_VERSION"]
|
||||||
new_version = current_version.next
|
|
||||||
|
version = Semantic::Version.new(current_version)
|
||||||
|
|
||||||
|
new_version = version.increment!(:patch)
|
||||||
|
|
||||||
# Bump the patch version. The empty string after -i is so that sed doesn't
|
# Bump the patch version. The empty string after -i is so that sed doesn't
|
||||||
# create a backup file on macOS
|
# create a backup file on macOS
|
||||||
sh("sed -i '' 's/#{current_version}/#{new_version}/g' #{target_file_path}")
|
sh("sed -i '' 's/MARKETING_VERSION: #{current_version}/MARKETING_VERSION: #{new_version.to_string}/g' #{target_file_path}")
|
||||||
|
|
||||||
xcodegen(spec: "project.yml")
|
xcodegen(spec: "project.yml")
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user