在终端中使用 cordova run ios
后停止运行的命令是什么?
我找到了一个关于这个问题的主题,其中1个答案说它是 quit
但是没有用 . 现在我每次关闭终端都非常耗时 .
如果我按ctrl c我得到以下内容:
(lldb)^ CTraceback(最近一次调用最后一次):文件“/private/tmp/fruitstrap_.py”,第17行,在connect_command事件中= lldb.SBEvent()文件“/Applications/Xcode.app/Contents/SharedFrameworks/ LLDB.framework / Versions / A / Resources / Python / lldb / init.py“,第3395行,在init this = lldb.new_SBEvent(* args)KeyboardInterrupt错误:平台当前未连接执行'/ tmp / fruitstrap中的命令-lldb-准备-cmds-” . (lldb)平台选择remote-ios --sysroot'/ Users / doekewartena / Library / Developer / Xcode / iOS DeviceSupport / 7.1.2(11D257)/ Symbols'平台:remote-ios已连接:无SDK路径:“/ Users / doekewartena / Library / Developer / Xcode / iOS DeviceSupport / 7.1.2(11D257)/ Symbols“(lldb)target create”/Users/doekewartena/Documents/jbc2014/platforms/ios/build/device/JBC2014.app“当前可执行集到'/Users/doekewartena/Documents/jbc2014/platforms/ios/build/device/JBC2014.app'(armv7) . (lldb)script fruitstrap_device_app =“/ private / var / mobile / Applications / E23498AF-29C5-4A9F-8AFB-6566631DB725 / JBC2014.app”(lldb)script fruitstrap_connect_url =“connect://127.0.0.1:12345”(lldb)命令脚本导入“/tmp/fruitstrap.py”(lldb)命令脚本add -f fruitstrap_.connect_command connect(lldb)命令脚本add -s asynchronous -f fruitstrap_.run_command run(lldb)命令脚本add -s asynchronous -f fruitstrap_ .autoexit_command autoexit(lldb)connect(lldb)run
10 回答
如果使用cordova cli构建项目,则Xcode不应该运行 . 这很可能会解决您的问题 .
这可能是因为
ios-deploy
的早期版本,因为它被描述为here .检查你的ios-deploy版本,我的是1.0.8:
检查nos版本的ios-deploy,当前为1.1.0:
通过npm更新ios-deploy:
在
$ cordova run
之后,您现在可以输入exit
并按ENTER . 在此之后,键入y
并按Enter以退出该过程 .尝试了很多不同的建议之后,唯一对我有用的是打开另一个终端窗口,当你完成调试运行时:
pkill lldb
这将关闭手机上的应用程序,并且整齐地返回原始终端窗口的命令提示符 .
我输入“exit”然后按Y并按Enter键 . 这在lldb停止时有效 .
如果你在调试阶段之后但在它说(lldb)之前使用Ctrl-C它会退出...
只需按
CTRL+C
(在大多数unix shell中)我仍然发现这是Cordova 5.1.1 CLI的一个问题 .
我发现在运行lldb的终端窗口中按下Ctrl Z对我有效 .
在我的情况下,这取决于我运行应用程序的方式 .
如果我使用
phonegap run ios
运行应用程序,我必须按Ctrl + C
;但如果我使用cordova run ios
运行,我也可以退出quit
或exit
在lldb
(应用程序运行后),然后按Y
.作为旁注:当我退出按
Ctrl + C
,然后拔下我的设备并删除应用程序后,再次插入我的设备lldb
尝试再次安装应用程序,而不是询问 . 当我退出键入exit
时,这不会发生 .如果您在Mac上使用终端,则可以使用
Command + C
.运行
ionic cordova run browser
时遇到了类似的问题 . 推CTRL-C
刚终止了终端进程,但服务器在后台运行 .我在mac上的解决方案是去活动监视器并杀死名为
node
的进程 .