Fix previous merges

Build scripts (create and build) were mangled somewhat by the previous
merge commits. This resets them to (almost) exactly the same state as
the 3.6.x (master) branch.

Conflicts:
        bin/lib/create.js


Project: http://git-wip-us.apache.org/repos/asf/cordova-android/repo
Commit: http://git-wip-us.apache.org/repos/asf/cordova-android/commit/7caa96ab
Tree: http://git-wip-us.apache.org/repos/asf/cordova-android/tree/7caa96ab
Diff: http://git-wip-us.apache.org/repos/asf/cordova-android/diff/7caa96ab

Branch: refs/heads/4.0.x
Commit: 7caa96abcdfee71712a7a4e8aa65b128e3f6efc4
Parents: b277626
Author: Ian Clelland <[email protected]>
Authored: Wed Aug 20 11:17:04 2014 -0400
Committer: Ian Clelland <[email protected]>
Committed: Wed Aug 20 11:45:35 2014 -0400

----------------------------------------------------------------------
 bin/lib/create.js                  | 18 ------------------
 bin/templates/cordova/lib/build.js |  1 -
 2 files changed, 19 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cordova-android/blob/7caa96ab/bin/lib/create.js
----------------------------------------------------------------------
diff --git a/bin/lib/create.js b/bin/lib/create.js
index 6a5fe57..4b340c6 100755
--- a/bin/lib/create.js
+++ b/bin/lib/create.js
@@ -119,7 +119,6 @@ function writeProjectProperties(projectPath, target_api, 
shared) {
 
 function copyBuildRules(projectPath) {
     var srcDir = path.join(ROOT, 'bin', 'templates', 'project');
-    shell.cp('-f', path.join(srcDir, 'custom_rules.xml'), projectPath);
 
     shell.cp('-f', path.join(srcDir, 'build.gradle'), projectPath);
     shell.cp('-f', path.join(srcDir, 'settings.gradle'), projectPath);
@@ -139,13 +138,6 @@ function copyScripts(projectPath) {
     shell.cp(path.join(ROOT, 'bin', 'lib', 'android_sdk_version.js'), 
path.join(projectPath, 'cordova', 'lib', 'android_sdk_version.js'));
 }
 
-function copyGradleWrapper(sdkPath, projectPath) {
-    var wrapperDir = path.join(sdkPath, 'tools', 
'templates','gradle','wrapper');
-    shell.cp(path.join(wrapperDir, 'gradlew'), projectPath);
-    shell.cp(path.join(wrapperDir, 'gradlew.bat'), projectPath);
-    shell.cp('-r', path.join(wrapperDir, 'gradle'), projectPath);
-}
-
 /**
  * Test whether a package name is acceptable for use as an android project.
  * Returns a promise, fulfilled if the package name is acceptable; rejected
@@ -254,16 +246,6 @@ exports.createProject = function(project_path, 
package_name, project_name, proje
             shell.cp('-r', path.join(ROOT, 'framework', 'res', 'xml'), 
path.join(project_path, 'res'));
             shell.cp(path.join(project_template_dir, 'gitignore'), 
path.join(project_path, '.gitignore'));
 
-            shell.cp('-f', path.join(project_template_dir, 'build.gradle'), 
project_path);
-            shell.cp('-f', path.join(project_template_dir, 
'libraries.gradle'), project_path);
-            shell.cp('-f', path.join(project_template_dir, 'settings.gradle'), 
project_path);
-            check_reqs.sdk_dir().then(function(dir) {
-                console.log("Copying Gradle wrapper from " + dir);
-                copyGradleWrapper(dir, project_path);
-            }).catch(function(err) {
-                console.log("Cannot find Android SDK. Not installing Gradle 
wrapper.");
-            });
-
             // Manually create directories that would be empty within the 
template (since git doesn't track directories).
             shell.mkdir(path.join(project_path, 'libs'));
 

http://git-wip-us.apache.org/repos/asf/cordova-android/blob/7caa96ab/bin/templates/cordova/lib/build.js
----------------------------------------------------------------------
diff --git a/bin/templates/cordova/lib/build.js 
b/bin/templates/cordova/lib/build.js
index 7d8828d..1f4810d 100644
--- a/bin/templates/cordova/lib/build.js
+++ b/bin/templates/cordova/lib/build.js
@@ -24,7 +24,6 @@ var shell   = require('shelljs'),
     Q       = require('q'),
     path    = require('path'),
     fs      = require('fs'),
-    which   = require('which'),
     ROOT    = path.join(__dirname, '..', '..');
 var check_reqs = require('./check_reqs');
 

Reply via email to