[英]Why is my Eclipse launch configuration not being added to the Run or Debug configurations list?
I have a .launch file which I can run by context menu (Run As...), but it is not being added to the list of Debug or Run configurations like it should.我有一个 .launch 文件,我可以通过上下文菜单(运行方式...)运行它,但它没有像它应该的那样被添加到调试或运行配置列表中。 Why not?
为什么不呢?
There is something wrong with the launch config.启动配置有问题。 Possibly a project is being referenced which is closed (that's what it was for me)...
可能正在引用一个已关闭的项目(这对我来说就是这样)......
So the launch may work (in my case this was because the project wasn't actually required) but any issues like this will cause it not to be added to the list of launches.所以启动可能会起作用(在我的情况下,这是因为该项目实际上并不是必需的),但任何类似的问题都将导致它不会被添加到启动列表中。 To figure out what the cause is, you can
要找出原因是什么,您可以
这可能有任何帮助,但我认为在导入项目时,它会被添加到“运行配置”的常规列表中,但是当我添加一个 java 运行配置时,它会被添加到 Eclipse“运行”中的“Java 应用程序”父节点配置”。
For me, this happens due to copy the same project and giving the other name so my project name is not showing in the launch configuration (for not showing in the launch configuration there could be some other reasons.)对我来说,发生这种情况是因为复制了同一个项目并给出了另一个名称,所以我的项目名称没有显示在启动配置中(因为没有显示在启动配置中,可能有其他一些原因。)
Fix:修复:
Right-click on the project select Coverage as after this will get two option java application and configuration.右键单击项目选择 Coverage 之后将获得两个选项 java application 和 configuration。
select java application it will run the project and create the coverage.选择 java 应用程序,它将运行项目并创建覆盖范围。
Other option is just run the Application it will create the coverage.其他选项只是运行将创建覆盖范围的应用程序。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.