Skip to main content



      Home
Home » Modeling » TMF (Xtext) » Generated code (What is never modified and can be ignored?)
Generated code [message #1787121] Sat, 19 May 2018 05:26 Go to next message
Eclipse UserFriend
Hi,

I have noticed that xtext projects generally have 3 source folders:


  1. src/
  2. src-gen/
  3. xtend-gen/


Now, typically running the mwe2 to generate stuff, creates files in all 3 locations. Stuff in src/ is actually meant to be edited (e.g. the generated xtend file).

Is it safe to say that "src-gen" and "xtend-gen" are always overwritten (so they could be ignored and never be edited or imported into source control) but stuff under "src" should be imported and tracked?

Sorry for the very basic questions but it's the first time I'm using xtext seriously so in this case I want to set things up correctly.

Thanks
Re: Generated code [message #1787123 is a reply to message #1787121] Sat, 19 May 2018 06:19 Go to previous messageGo to next message
Eclipse UserFriend
Short answer yes
*-gen is generated code

There might be reasons to track it with version
Control but often there are set to be ignored
Re: Generated code [message #1787140 is a reply to message #1787123] Sat, 19 May 2018 10:21 Go to previous message
Eclipse UserFriend
Placing the generated code under version control or exluding them from it have both advantages and disadvantages.
See the discussion of the Xtext team:
https://github.com/eclipse/xtext/issues/1066
Previous Topic:Validating x,y coordinates
Next Topic:Unsuccessful build using Maven due missing EMF classes
Goto Forum:
  


Current Time: Wed Jun 18 14:10:57 EDT 2025

Powered by FUDForum. Page generated in 0.13860 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top