无法使用forcedroid安装cordova-plugin-whitelist从salesforce

时间:2015-07-09 11:47:06

标签: android node.js salesforce cordova-plugins

我正在尝试创建一个强大的混合Android应用程序。输入forcedroid create命令后,我得到以下日志

C:\Git>forcedroid create
Enter your application type (native, hybrid_remote, or hybrid_local): hybrid_local
Enter your application name: test
Enter the target directory of your app: ibeaconapp
Enter the package name for your app (com.mycompany.my_app): com.yameen.test
Creating a new cordova project.
C:\Git\ibeaconapp\test C:\Git
Adding android project...
Creating Cordova project for the Android platform:
        Path: platforms\android
        Package: com.yameen.test
        Name: test
        Android target: android-19
Copying template files...
Project successfully created.
Discovered plugin "cordova-plugin-whitelist" in config.xml. Installing to the project
Fetching plugin "cordova-plugin-whitelist@1" via npm
npm http GET http://registry.npmjs.org/cordova-plugin-whitelist
npm http 304 http://registry.npmjs.org/cordova-plugin-whitelist
Installing "cordova-plugin-whitelist" for android

安装cordova-plugin-whitelist会出错:

Installing "cordova-plugin-whitelist" for android
Failed to install 'cordova-plugin-whitelist':CordovaError: Plugin doesn't support this project's cordova-android version. cordova-android: 3.6.4, failed ve
rsion requirement: >=4.0.0-dev
    at checkEngines (C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\src\plugman\install.js:119:29)
    at C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\src\plugman\install.js:296:16
    at _fulfilled (C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\q\q.js:787:54)
    at self.promiseDispatch.done (C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\q\q.js:816:30)
    at Promise.promise.promiseDispatch (C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\q\q.js:749:13)
    at C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\q\q.js:557:44
    at flush (C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\q\q.js:108:17)
    at process._tickCallback (node.js:355:11)
Installing "cordova-plugin-whitelist" for android
Failed to install 'cordova-plugin-whitelist':CordovaError: Plugin doesn't support this project's cordova-android version. cordova-android: 3.6.4, failed ve
rsion requirement: >=4.0.0-dev
    at checkEngines (C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\src\plugman\install.js:119:29)
    at C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\src\plugman\install.js:296:16
    at _fulfilled (C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\q\q.js:787:54)
    at self.promiseDispatch.done (C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\q\q.js:816:30)
    at Promise.promise.promiseDispatch (C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\q\q.js:749:13)
    at C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\q\q.js:557:44
    at flush (C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\q\q.js:108:17)
    at process._tickCallback (node.js:355:11)
Plugin doesn't support this project's cordova-android version. cordova-android: 3.6.4, failed version requirement: >=4.0.0-dev
Fetching plugin "https://github.com/forcedotcom/SalesforceMobileSDK-CordovaPlugin" via git clone
Error: C:\Users\M1026752\AppData\Local\GitHub\PortableGit_c2ba306e536fdf878271f7fe636a147ff37326ad\libexec\git-core\git.exe: Command failed with exit code
128 Error output:
Cloning into 'C:\Users\M1026752\AppData\Local\Temp\git\1436441765068'...
    at ChildProcess.whenDone (C:\Users\M1026752\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\src\cordova\superspawn.js:134:23)
    at ChildProcess.emit (events.js:110:17)
    at maybeClose (child_process.js:1008:16)
    at Process.ChildProcess._handle.onexit (child_process.js:1080:5)
C:\Git

我无法解决这个问题。我甚至检查了我的cordova版本

C:\Git>cordova -v
5.1.1

0 个答案:

没有答案