16
16
* -PandroidXLegacy=[androidx_legacy_version]
17
17
* -PandroidXAppCompat=[androidx_appcompat_version]
18
18
* -PandroidXMaterial=[androidx_material_version]
19
+ * -PappPath=[app_path]
20
+ * -PappResourcesPath=[app_resources_path]
19
21
*/
20
22
21
23
@@ -125,7 +127,11 @@ version of the {N} CLI install a previous version of the runtime package - 'tns
125
127
nsConfig = new JsonSlurper (). parseText(nsConfigFile. getText(" UTF-8" ))
126
128
}
127
129
128
- if (nsConfig != null && nsConfig. appPath != null ) {
130
+ if (project. hasProperty(" appPath" )) {
131
+ // when appPath is passed through -PappPath=/path/to/app
132
+ // the path could be relative or absolute - either case will work
133
+ relativePathToApp = appPath
134
+ } else if (nsConfig != null && nsConfig. appPath != null ) {
129
135
relativePathToApp = nsConfig. appPath
130
136
}
131
137
@@ -144,7 +150,12 @@ version of the {N} CLI install a previous version of the runtime package - 'tns
144
150
nsConfig = new JsonSlurper (). parseText(nsConfigFile. getText(" UTF-8" ))
145
151
}
146
152
147
- if (nsConfig != null && nsConfig. appResourcesPath != null ) {
153
+ if (project. hasProperty(" appResourcesPath" )) {
154
+ // when appResourcesPath is passed through -PappResourcesPath=/path/to/App_Resources
155
+ // the path could be relative or absolute - either case will work
156
+ relativePathToAppResources = appResourcesPath
157
+ absolutePathToAppResources = java.nio.file.Paths . get(USER_PROJECT_ROOT ). resolve(relativePathToAppResources). toAbsolutePath()
158
+ } else if (nsConfig != null && nsConfig. appResourcesPath != null ) {
148
159
relativePathToAppResources = nsConfig. appResourcesPath
149
160
absolutePathToAppResources = java.nio.file.Paths . get(USER_PROJECT_ROOT ). resolve(relativePathToAppResources). toAbsolutePath()
150
161
} else {
0 commit comments