简体   繁体   English

Visual Studio 2015 Cordova Android设备错误

[英]Visual studio 2015 Cordova Android Error with device

I am using 2015 CTP 6. I have correct JAVA_HOME and all other variables set. 我正在使用2015 CTP6。我已经设置了正确的JAVA_HOME和所有其他变量。 Here is my env. 这是我的环境。

angularjs 1.3.14 angularjs 1.3.14

jQuery 1.8.0 jQuery 1.8.0

JAVA_HOME = C:\\Program Files\\Java\\jdk1.8.0_40 JAVA_HOME = C:\\ Program Files \\ Java \\ jdk1.8.0_40

ADT_HOME = C:\\Users\\MyUserName\\AppData\\Local\\Android\\android-sdk ADT_HOME = C:\\ Users \\ MyUserName \\ AppData \\ Local \\ Android \\ android-sdk

ANT_HOME =C:\\apache-ant-1.9.4-bin\\apache-ant-1.9.4 ANT_HOME = C:\\ apache-ant-1.9.4-bin \\ apache-ant-1.9.4

Node.js verion 0.12.2 Node.js版本0.12.2

Everything works fine in Ripple emulator. 在Ripple模拟器中一切正常。

I get this error while deploying to device. 部署到设备时出现此错误。 Device is connected, unlock. 设备已连接,请解锁。

Command failed with exit code 1 ------------ Detail error ---------- 命令失败,退出代码为1 ------------详细错误----------

1> C:\\sourcecode\\bld\\Debug\\platforms\\android\\cordova\\node_modules\\q\\q.js:1 (TaskId:11) 1> C:\\ sourcecode \\ bld \\ Debug \\ platforms \\ android \\ cordova \\ node_modules \\ q \\ q.js:1(TaskId:11)

1> (function (exports, require, module, __filename, __dirname) { C:\\sourcecode\\Ch (TaskId:11) 1>(函数(导出,需求,模块,__ filename,__ dirname){C:\\ sourcecode \\ Ch(TaskId:11)

1> ^ (TaskId:11) 1> ^(TaskId:11)

1> SyntaxError: Unexpected token ILLEGAL (TaskId:11) 1> SyntaxError:意外的令牌非法(TaskId:11)

1> at exports.runInThisContext (vm.js:73:16) (TaskId:11) 1>位于exports.runInThisContext(vm.js:73:16)(TaskId:11)

1> at Module._compile (module.js:443:25) (TaskId:11) 1>在Module._compile(module.js:443:25)(TaskId:11)

(C:\\sourcecode\\bld\\Debug\\platforms\\android\\cordova\\lib\\exec.js:23:15) (TaskId:11) (C:\\ sourcecode \\ bld \\ Debug \\ platforms \\ android \\ cordova \\ lib \\ exec.js:23:15)(TaskId:11)

1> at Module._compile (module.js:460:26) (TaskId:11) 1>在Module._compile(module.js:460:26)(TaskId:11)

1> at Object.Module._extensions..js (module.js:478:10) (TaskId:11) 1>在Object.Module._extensions..js(module.js:478:10)(TaskId:11)

1> Command finished with error code 1: C:\\sourcecode\\bld\\Debug\\platforms\\android\\cordova\\build.bat --debug,--ant, (TaskId:11) 1>命令以错误代码1完成:C:\\ sourcecode \\ bld \\ Debug \\ platforms \\ android \\ cordova \\ build.bat --debug,-ant,(TaskId:11)

1>MDAVSCLI : error : 1> MDAVSCLI:错误:

C:\\sourcecode\\bld\\Debug\\platforms\\android\\cordova\\build.bat: Command failed with exit code 1 C:\\ sourcecode \\ bld \\ Debug \\ platforms \\ android \\ cordova \\ build.bat:命令失败,退出代码为1

It seems like there might be a invalid/hidden character in your project code files. 您的项目代码文件中似乎有一个无效/隐藏的字符。 Have you tried sanitizing it as described here ? 您是否尝试过按照此处所述对其进行消毒?

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM