Compare commits

...

12 Commits
6.3.0 ... 6.1.1

Author SHA1 Message Date
Steve Gill
96457effbc Set VERSION to 6.1.1 (via coho) 2017-01-03 17:45:53 -08:00
Steve Gill
67e7980eba Update JS snapshot to version 6.1.1 (via coho) 2017-01-03 17:45:53 -08:00
Steve Gill
0efa6cd766 CB-12314 Updated RELEASENOTES and Version for release 6.1.1 2017-01-03 17:42:13 -08:00
daserge
a51fc4b25e CB-12159 Android: Keystore password prompt won't show up
This closes #351
2017-01-03 17:21:39 -08:00
Joe Bowser
071ddbf6eb Adding isClean to the spec, this really should have failed a few commits ago
This closes #349
2017-01-03 17:21:24 -08:00
Joe Bowser
a87eb7266f Need to pass lint 2017-01-03 17:21:05 -08:00
Joe Bowser
c2ddd2da7f CB-12169: Check for build directory before running a clean 2017-01-03 17:20:26 -08:00
Joe Bowser
e856613787 Updating the timeout due to known travis issues 2016-11-03 12:49:40 -07:00
Jesse MacFadyen
94e9bd5e26 Do not test for non-existent build folder
This closes #348
2016-11-03 12:49:30 -07:00
Jesse MacFadyen
011b57da54 Fixed AndroidStudio tests to actually run, removed app/src/main/assets/ as a requirement and added app/src/main/res instead, added placeholder for build/ folder, Removed dupe gitignore 2016-11-03 12:49:18 -07:00
Joe Bowser
7e54af75d8 Set VERSION to 6.1.0 (via coho) 2016-11-02 16:32:15 -07:00
Joe Bowser
d95df96881 Update JS snapshot to version 6.1.0 (via coho) 2016-11-02 16:32:15 -07:00
16 changed files with 105 additions and 78 deletions

1
.gitignore vendored
View File

@@ -40,7 +40,6 @@ Desktop.ini
*.iml
.idea
npm-debug.log
/framework/build
node_modules/jshint
node_modules/promise-matchers
node_modules/jasmine-node

View File

@@ -20,6 +20,11 @@
-->
## Release Notes for Cordova (Android) ##
### 6.1.1 (Jan 03, 2017)
* [CB-12159](https://issues.apache.org/jira/browse/CB-12159) **Android** Keystore password prompt won't show up
* [CB-12169](https://issues.apache.org/jira/browse/CB-12169) Check for build directory before running a clean
* Fixed `AndroidStudio` tests to actually run, removed `app/src/main/assets/` as a requirement and added `app/src/main/res` instead, added placeholder for `build/` folder, Removed dupe `gitignore`
### 6.1.0 (Nov 02, 2016)
* [CB-12108](https://issues.apache.org/jira/browse/CB-12108) Updating gradle files to work with the latest version of Android Studio
* [CB-12102](https://issues.apache.org/jira/browse/CB-12102) Bump travis to build to API 25

View File

@@ -1 +1 @@
6.1.0-dev
6.1.1

View File

@@ -72,6 +72,7 @@ function Api(platform, platformRootDir, events) {
defaultConfigXml: path.join(self.root, 'cordova/defaults.xml'),
strings: path.join(self.root, 'res/values/strings.xml'),
manifest: path.join(self.root, 'AndroidManifest.xml'),
build: path.join(self.root, 'build'),
// NOTE: Due to platformApi spec we need to return relative paths here
cordovaJs: 'bin/templates/project/assets/www/cordova.js',
cordovaJsSrc: 'cordova-js-src'
@@ -241,11 +242,12 @@ Api.prototype.addPlugin = function (plugin, installOptions) {
// Do some basic argument parsing
var opts = {};
// Skip cleaning prepared files when not invoking via cordova CLI.
// Skip cleaning prepared files when not invoking via cordova CLI.
opts.noPrepare = true;
if(!(AndroidStudio.isAndroidStudioProject(self.root)))
if(!AndroidStudio.isAndroidStudioProject(self.root) && !project.isClean()) {
return self.clean(opts);
}
})
.then(function () {
return PluginManager.get(self.platform, self.locations, project)
@@ -396,6 +398,8 @@ Api.prototype.clean = function(cleanOptions) {
});
};
/**
* Performs a requirements check for current platform. Each platform defines its
* own set of requirements, which should be resolved before platform can be

View File

@@ -197,5 +197,14 @@ AndroidProject.prototype.getUninstaller = function (type) {
return pluginHandlers.getUninstaller(type);
};
/*
* This checks if an Android project is clean or has old build artifacts
*/
AndroidProject.prototype.isClean = function() {
var build_path = path.join(this.projectDir, 'build');
//If the build directory doesn't exist, it's clean
return !(fs.existsSync(build_path));
};
module.exports = AndroidProject;

View File

@@ -8,15 +8,20 @@
var path = require('path');
var fs = require('fs');
var CordovaError = require('cordova-common').CordovaError;
module.exports.isAndroidStudioProject = function isAndroidStudioProject(root) {
var eclipseFiles = ['AndroidManifest.xml', 'libs', 'res', 'project.properties', 'platform_www'];
var androidStudioFiles = ['app', 'gradle', 'build', 'app/src/main/assets'];
var androidStudioFiles = ['app', 'gradle', 'app/src/main/res'];
// assume it is an AS project and not an Eclipse project
var isEclipse = false;
var isAS = true;
if(!fs.existsSync(root)) {
throw new CordovaError('AndroidStudio.js:inAndroidStudioProject root does not exist: ' + root);
}
// if any of the following exists, then we are not an ASProj
eclipseFiles.forEach(function(file) {
if(fs.existsSync(path.join(root, file))) {
@@ -28,6 +33,7 @@ module.exports.isAndroidStudioProject = function isAndroidStudioProject(root) {
if(!isEclipse) {
androidStudioFiles.forEach(function(file){
if(!fs.existsSync(path.join(root, file))) {
console.log('missing file :: ' + file);
isAS = false;
}
});

View File

@@ -20,7 +20,7 @@
*/
// Coho updates this line:
var VERSION = "6.1.0-dev";
var VERSION = "6.1.1";
module.exports.version = VERSION;

View File

@@ -1,5 +1,5 @@
// Platform: android
// 53ea1913735222d326e65326e03391405df3cd4e
// a3732cb71d9b1dd590338e8cf44196f366d46da3
/*
Licensed to the Apache Software Foundation (ASF) under one
or more contributor license agreements. See the NOTICE file
@@ -19,7 +19,7 @@
under the License.
*/
;(function() {
var PLATFORM_VERSION_BUILD_LABEL = '6.1.0-dev';
var PLATFORM_VERSION_BUILD_LABEL = '6.1.1';
// file: src/scripts/require.js
/*jshint -W079 */
@@ -330,7 +330,7 @@ module.exports = cordova;
});
// file: /Users/jbowser/cordova/cordova-android/cordova-js-src/android/nativeapiprovider.js
// file: /Users/steveng/repo/cordova/cordova-android/cordova-js-src/android/nativeapiprovider.js
define("cordova/android/nativeapiprovider", function(require, exports, module) {
/**
@@ -353,7 +353,7 @@ module.exports = {
});
// file: /Users/jbowser/cordova/cordova-android/cordova-js-src/android/promptbasednativeapi.js
// file: /Users/steveng/repo/cordova/cordova-android/cordova-js-src/android/promptbasednativeapi.js
define("cordova/android/promptbasednativeapi", function(require, exports, module) {
/**
@@ -886,7 +886,7 @@ module.exports = channel;
});
// file: /Users/jbowser/cordova/cordova-android/cordova-js-src/exec.js
// file: /Users/steveng/repo/cordova/cordova-android/cordova-js-src/exec.js
define("cordova/exec", function(require, exports, module) {
/**
@@ -1649,7 +1649,7 @@ exports.reset();
});
// file: /Users/jbowser/cordova/cordova-android/cordova-js-src/platform.js
// file: /Users/steveng/repo/cordova/cordova-android/cordova-js-src/platform.js
define("cordova/platform", function(require, exports, module) {
// The last resume event that was received that had the result of a plugin call.
@@ -1759,7 +1759,7 @@ function onMessageFromNative(msg) {
});
// file: /Users/jbowser/cordova/cordova-android/cordova-js-src/plugin/android/app.js
// file: /Users/steveng/repo/cordova/cordova-android/cordova-js-src/plugin/android/app.js
define("cordova/plugin/android/app", function(require, exports, module) {
var exec = require('cordova/exec');

View File

@@ -264,7 +264,7 @@ def promptForReleaseKeyPassword() {
gradle.taskGraph.whenReady { taskGraph ->
taskGraph.getAllTasks().each() { task ->
if (task.name == 'validateReleaseSigning') {
if (task.name == 'validateReleaseSigning' || task.name == 'validateSigningRelease') {
promptForReleaseKeyPassword()
}
}

View File

@@ -31,7 +31,7 @@ import android.webkit.WebChromeClient.CustomViewCallback;
* are not expected to implement it.
*/
public interface CordovaWebView {
public static final String CORDOVA_VERSION = "6.1.0-dev";
public static final String CORDOVA_VERSION = "6.1.1";
void init(CordovaInterface cordova, List<PluginEntry> pluginEntries, CordovaPreferences preferences);

View File

@@ -1,49 +1,49 @@
{
"name": "cordova-android",
"version": "6.1.0",
"description": "cordova-android release",
"bin": {
"create": "bin/create"
},
"main": "bin/templates/cordova/Api.js",
"repository": {
"type": "git",
"url": "https://git-wip-us.apache.org/repos/asf/cordova-android.git"
},
"keywords": [
"android",
"cordova",
"apache"
],
"scripts": {
"test": "npm run jshint && jasmine-node --color spec/unit",
"cover": "istanbul cover --root bin/templates/cordova --print detail node_modules/jasmine-node/bin/jasmine-node -- spec/unit",
"test-build": "jasmine-node --captureExceptions --color spec/e2e",
"jshint": "node node_modules/jshint/bin/jshint bin && node node_modules/jshint/bin/jshint spec"
},
"author": "Apache Software Foundation",
"license": "Apache-2.0",
"dependencies": {
"cordova-common": "^1.5.0",
"elementtree": "^0.1.6",
"nopt": "^3.0.1",
"properties-parser": "^0.2.3",
"q": "^1.4.1",
"shelljs": "^0.5.3"
},
"bundledDependencies": [
"cordova-common",
"elementtree",
"nopt",
"properties-parser",
"q",
"shelljs"
],
"devDependencies": {
"istanbul": "^0.4.2",
"jasmine-node": "^1.14.5",
"jshint": "^2.6.0",
"promise-matchers": "~0",
"rewire": "^2.1.3"
}
"name": "cordova-android",
"version": "6.1.1",
"description": "cordova-android release",
"bin": {
"create": "bin/create"
},
"main": "bin/templates/cordova/Api.js",
"repository": {
"type": "git",
"url": "https://git-wip-us.apache.org/repos/asf/cordova-android.git"
},
"keywords": [
"android",
"cordova",
"apache"
],
"scripts": {
"test": "npm run jshint && jasmine-node --color spec/unit",
"cover": "istanbul cover --root bin/templates/cordova --print detail node_modules/jasmine-node/bin/jasmine-node -- spec/unit",
"test-build": "jasmine-node --captureExceptions --color spec/e2e",
"jshint": "node node_modules/jshint/bin/jshint bin && node node_modules/jshint/bin/jshint spec"
},
"author": "Apache Software Foundation",
"license": "Apache-2.0",
"dependencies": {
"cordova-common": "^1.5.0",
"elementtree": "^0.1.6",
"nopt": "^3.0.1",
"properties-parser": "^0.2.3",
"q": "^1.4.1",
"shelljs": "^0.5.3"
},
"bundledDependencies": [
"cordova-common",
"elementtree",
"nopt",
"properties-parser",
"q",
"shelljs"
],
"devDependencies": {
"istanbul": "^0.4.2",
"jasmine-node": "^1.14.5",
"jshint": "^2.6.0",
"promise-matchers": "~0",
"rewire": "^2.1.3"
}
}

View File

@@ -20,7 +20,7 @@
var path = require('path'),
actions = require('./helpers/projectActions.js');
var PLUGIN_ADD_TIMEOUT = 60000;
var PLUGIN_ADD_TIMEOUT = 90000;
describe('plugin add', function() {

View File

@@ -0,0 +1 @@
Tests require that this folder exists.

View File

@@ -1,14 +0,0 @@
var AndroidStudio = require('../../bin/templates/cordova/lib/AndroidStudio');
describe('AndroidStudio module', function () {
it('should detect Android Studio project', function() {
var root = './fixtures/android_studio_project';
spyOn(AndroidStudio, 'isAndroidStudioProject').andReturn(true);
AndroidStudio.isAndroidStudioProject(root);
});
it('should detect non Android Studio project', function() {
var root = './fixtures/android_project';
spyOn(AndroidStudio, 'isAndroidStudioProject').andReturn(false);
AndroidStudio.isAndroidStudioProject(root);
});
});

View File

@@ -0,0 +1,17 @@
var path = require('path');
var AndroidStudio = require('../../bin/templates/cordova/lib/AndroidStudio');
describe('AndroidStudio module', function () {
it('should return true for Android Studio project', function() {
var root = path.join(__dirname,'../fixtures/android_studio_project/');
var isAndStud = AndroidStudio.isAndroidStudioProject(root);
expect(isAndStud).toBe(true);
});
it('should return false non Android Studio project', function() {
var root = path.join(__dirname,'../fixtures/android_project/');
var isAndStud = AndroidStudio.isAndroidStudioProject(root);
expect(isAndStud).toBe(false);
});
});

View File

@@ -42,7 +42,7 @@ describe('addPlugin method', function () {
pluginManager.addPlugin.andReturn(Q());
spyOn(common.PluginManager, 'get').andReturn(pluginManager);
var projectSpy = jasmine.createSpyObj('AndroidProject', ['getPackageName', 'write']);
var projectSpy = jasmine.createSpyObj('AndroidProject', ['getPackageName', 'write', 'isClean']);
spyOn(AndroidProject, 'getProjectFile').andReturn(projectSpy);
oldClean = Api.__get__('Api.prototype.clean');