-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathFastfile
95 lines (81 loc) · 2.87 KB
/
Fastfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
# VERSION CODE
# update the flutter version code by 1
# eg 1.1.1+1 -> 1.1.1+2
lane :update_version_code do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml",
version_component: "version_code")
end
# if you dont specify `version_component` version_code will the default value
lane :update_version_default do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml", value: "9")
end
# set the flutter version - patch to `value` given
# eg 1.1.1+1 -> 1.1.1+100
lane :set_version_code do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml",
value: "100",
version_component: "version_code")
end
# VERSION - PATCH
# update the flutter version - patch by 1
# eg 1.1.1 -> 1.1.2
lane :update_version_patch do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml",
version_component: "patch")
end
# set the flutter version - patch to `value` given
# eg 1.1.1 -> 1.1.100
lane :set_version_patch do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml",
value: "100",
version_component: "patch")
end
# VERSION - MINOR
# update the flutter version - minor by 1 (also reset patch to 0)
# eg 1.1.1 -> 1.2.0
lane :update_version_minor do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml",
version_component: "minor")
end
# set the flutter version - major to `value` given (also reset patch to 0)
# eg 1.1.1 -> 1.100.0
lane :set_version_minor do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml",
value: "100",
version_component: "minor")
end
# VERSION - MAJOR
# update the flutter version - major by 1 (also reset minor and patch)
# eg 1.1.1 -> 2.0.0
lane :update_version_major do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml",
version_component: "major")
end
# set the flutter version - major to `value` given (also reset minor and patch)
# eg 1.1.1 -> 100.0.0
lane :set_version_major do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml",
value: "100",
version_component: "major")
end
# Error
lane :invalid_version_component do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml",
version_component: "invalid_version_component")
end
# VERSION NAME
# update the flutter version name to `value`
# eg 1.1.1+1 -> 2.3.4+1
lane :set_verion_name do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml",
value: "2.3.4",
version_component: "version_name")
end
# VERSION
# update the flutter version to `value`
# eg 1.1.1+1 -> 2.3.4+5
lane :set_version do
flutter_versioner(pubspec_file_path: "./example/pubspec.yaml",
value: "2.3.4+5",
version_component: "version")
end