Skip to content

Commit

Permalink
Update paths to work with cordova-android 7.x
Browse files Browse the repository at this point in the history
This is just to get things working for our project.

A real solution would probably need to support older cordova-android
versions, thus requiring some branching in the construction of these
paths.
  • Loading branch information
Nate Eagleson committed Aug 20, 2018
1 parent e840a7b commit 3e3d9a6
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 2 deletions.
8 changes: 7 additions & 1 deletion scripts/lib/buildVersionUpdater.js
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,13 @@ function increaseBuildVersion(cordovaContext) {
* @param {Object} cordovaContext - cordova's context
*/
function increaseBuildVersionForAndroid(cordovaContext, buildConfig) {
var androidManifestFilePath = path.join(cordovaContext.opts.projectRoot, 'platforms', ANDROID_PLATFORM, 'AndroidManifest.xml'),
var androidManifestFilePath = path.join(cordovaContext.opts.projectRoot,
'platforms',
ANDROID_PLATFORM,
'app',
'src',
'main',
'AndroidManifest.xml'),
manifestFileContent = xmlHelper.readXmlAsJson(androidManifestFilePath);

if (!manifestFileContent) {
Expand Down
10 changes: 9 additions & 1 deletion scripts/lib/chcpConfigXmlWriter.js
Original file line number Diff line number Diff line change
Expand Up @@ -80,7 +80,15 @@ function pathToIosConfigXml() {
* @return {String} absolute path to config.xml file
*/
function pathToAndroidConfigXml() {
return path.join(projectRoot, 'platforms', 'android', 'res', 'xml', 'config.xml');
return path.join(projectRoot,
'platforms',
'android',
'app',
'src',
'main',
'res',
'xml',
'config.xml');
}

/**
Expand Down

0 comments on commit 3e3d9a6

Please sign in to comment.