Skip to content
This repository has been archived by the owner on Oct 19, 2020. It is now read-only.

Commit

Permalink
Revert "added android version detection to automatically adjust outpu…
Browse files Browse the repository at this point in the history
…t folder"

This reverts commit 3bbc773.
  • Loading branch information
AlexDisler committed Feb 7, 2018
1 parent 6660c1a commit 233db74
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 20 deletions.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,3 @@ build/Release
# Deployed apps should consider commenting this line out:
# see https://npmjs.org/doc/faq.html#Should-I-check-my-node_modules-folder-into-git
node_modules
yarn.lock
19 changes: 1 addition & 18 deletions index.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ var colors = require('colors');
var _ = require('underscore');
var Q = require('q');
var argv = require('minimist')(process.argv.slice(2));
var semver = require('semver');

/**
* @var {Object} settings - names of the config file and of the icon image
Expand All @@ -16,22 +15,6 @@ settings.CONFIG_FILE = argv.config || 'config.xml';
settings.ICON_FILE = argv.icon || 'icon.png';
settings.OLD_XCODE_PATH = argv['xcode-old'] || false;


/**
* Get Android Folder based on Android Platform version
*/
var getAndroidFolder = function(){
var androidFolder = 'platforms/android/app/src/main/res/'; //as of [email protected]
if(!fs.existsSync('platforms/android/cordova/version')){
return androidFolder;
}
if(semver.lt(require('../../platforms/android/cordova/version').version, '7.0.0')){
androidFolder = 'platforms/android/res/';
}
return androidFolder;
}


/**
* Check which platforms are added to the project and return their icon names and sizes
*
Expand Down Expand Up @@ -86,7 +69,7 @@ var getPlatforms = function (projectName) {
platforms.push({
name : 'android',
isAdded : fs.existsSync('platforms/android'),
iconsPath : getAndroidFolder(),
iconsPath : 'platforms/android/res/',
icons : [
{ name : 'drawable/icon.png', size : 96 },
{ name : 'drawable-hdpi/icon.png', size : 72 },
Expand Down
1 change: 0 additions & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
"imagemagick": "^0.1.3",
"minimist": "^1.2.0",
"q": "^1.0.1",
"semver": "^5.5.0",
"underscore": "^1.6.0",
"xml2js": "^0.4.3"
}
Expand Down

0 comments on commit 233db74

Please sign in to comment.