fastlane-plugin-increment_version_build_number 0.0.1 → 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: c38ec05b205fb194bea4fd82307ee9ccc8a7f365466f228aee9e1e2bb176f65b
|
4
|
+
data.tar.gz: dd1804d25fd96c0caa261f42533bd54b923d9e6878fa29d14e251e218093ab22
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 9cf26349c6d205d35fc713eccc6b1f84049daa8857906636b1c676a7a40c70ec053f44cc28b4d333e9e5506e3297d81b3b50c6c08b998104ce2967d5d6e2ae14
|
7
|
+
data.tar.gz: 1554bc000882b8b6d346539bfb97a9fded6dd028ca733e9cb3ee76a106ea8c952a420fa2f63154d03c2f0f7f114f1e08adb7122f285addb39aeb9d797c771a85
|
@@ -52,13 +52,15 @@ module Fastlane
|
|
52
52
|
if line.include? constant_name and foundVersionBuildNumber=="false"
|
53
53
|
UI.message(" -> line: (#{line})!")
|
54
54
|
versionComponents = line.strip.split(' ')
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
55
|
+
if versionComponents[0] == constant_name
|
56
|
+
version_build_number = versionComponents[versionComponents.length-1].tr("\"","")
|
57
|
+
if new_version_build_number <= 0
|
58
|
+
new_version_build_number = version_build_number.to_i + 1
|
59
|
+
end
|
60
|
+
if !!(version_build_number =~ /\A[-+]?[0-9]+\z/)
|
61
|
+
line.replace line.sub(version_build_number, new_version_build_number.to_s)
|
62
|
+
foundVersionBuildNumber = "true"
|
63
|
+
end
|
62
64
|
end
|
63
65
|
temp_file.puts line
|
64
66
|
else
|
@@ -100,8 +102,8 @@ module Fastlane
|
|
100
102
|
optional: true,
|
101
103
|
type: String,
|
102
104
|
default_value: nil),
|
103
|
-
FastlaneCore::ConfigItem.new(key: :
|
104
|
-
env_name: "
|
105
|
+
FastlaneCore::ConfigItem.new(key: :version_build,
|
106
|
+
env_name: "IncrementVersionBuildNumber_version_build",
|
105
107
|
description: "Change to a specific version (optional)",
|
106
108
|
optional: true,
|
107
109
|
type: Integer,
|
@@ -111,7 +113,7 @@ module Fastlane
|
|
111
113
|
description: "If the version code is set in an ext constant, specify the constant name (optional)",
|
112
114
|
optional: true,
|
113
115
|
type: String,
|
114
|
-
default_value: "
|
116
|
+
default_value: "versionBuild")
|
115
117
|
]
|
116
118
|
end
|
117
119
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: fastlane-plugin-increment_version_build_number
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jems
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2024-01-
|
11
|
+
date: 2024-01-25 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: pry
|