挂钩到 Eclipse 构建过程? [英] Hook into the Eclipse build process?

查看:31
本文介绍了挂钩到 Eclipse 构建过程?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我希望能够在 Eclipse 中按下构建按钮时运行一个简单的 Java 程序.目前,当我单击构建时,它会运行一些 JRebel 日志记录代码.我有一个程序可以解析 JRebel 日志文件并将统计信息存储在数据库中.

I'd like to be able to run a simple Java program when the build button is pressed in Eclipse. Currently when I click build, it runs some JRebel logging code. I have a program that parses the JRebel log file and stores statistics in a DB.

是否可以编写一个插件或以某种方式挂钩到 Eclipse 的构建过程中,以便在 JRebel 日志记录完成后,它会运行我的程序来自动解析文件?

Is it possible to write a plugin or somehow hook into the build process of Eclipse, so that after the JRebel logging is done, it will run my program to parse the file automatically?

任何帮助都将不胜感激,即使您能指出我正确的方向.

Any help would be appreciated, even if you could just point me in the right direction.

提前致谢.

推荐答案

您可以将自定义 Builder 添加到您的 java 项目中.

You can add a custom Builder to your java project.

右键单击您的项目.选择属性.

Right-click on your project. Select Properties.

在左侧的树中选择Builders".

In the tree on the left side choose 'Builders'.

您可以添加 ant 脚本或特定程序.您还可以选择何时运行此工具(在 Java Builder 之前或之后).

You can either add an ant script or specific program. You also have ability to choose when this tool will be running ( before or after Java Builder ).

这篇关于挂钩到 Eclipse 构建过程?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆