2012-01-01 16 views
0

我在eclipse中設置了一個emftext示例項目。如果我通過eclipse的上下文菜單在* .cs文件中啓動「生成文本資源」,它工作正常。但是現在我想在一個maven項目中改變這個項目。通過pom.xml和tycho,我可以成功構建eclipse-plugin。但我無法通過maven或ant生成文本資源(創建編輯器項目)。如何通過ant在emftext中啓動生成?

http://www.emftext.org/EMFTextGuide.php#x1-120002.3.2手動的手段意味着螞蟻將支持它在日食的箱子。但它不起作用在我的電腦上。螞蟻的任務

<emftext.GenerateTextResource> 

它對日食中的螞蟻不瞭解。

也許我必須通過taskdef來定義它,但哪個* .jar我必須包含或哪個類或哪些類?

感謝提示。

回答

0

現在我已經找到了解決方案在emftext項目的示例代碼。 我必須爲Ant啓用eclipse外部工具設置「在與工作空間相同的JRE中運行」。現在在eclipse中它可以正常工作,而在maven中工作的轉換應該很簡單。

這裏是URL指向暗示的來源: http://svn-st.inf.tu-dresden.de/svn/reuseware/tags/20100922-emftext-1.3.1-jamopp-1.2.1/Build/org.reuseware/build-text-resources.xml.template

原來這裏是提示文本:

<!-- Define the EMF Generate Resource task. To have this task available, the plugin 
org.emftext.sdk.ant must be available in the classpath. To ensure this the external 
tools configuration needs to have the setting "Run in the same JRE as the workspace" 
enabled. -->