Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 336725 - Java Headers won't be updated
Summary: Java Headers won't be updated
Status: RESOLVED WONTFIX
Alias: None
Product: EMF
Classification: Modeling
Component: Core (show other bugs)
Version: unspecified   Edit
Hardware: PC Windows 7
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: Ed Merks CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-02-09 10:49 EST by Bernd Vogt CLA
Modified: 2011-02-10 04:33 EST (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Bernd Vogt CLA 2011-02-09 10:49:28 EST
Build Identifier: I20100608-0911

The headers of the generated java files won't be updated after changing the 'Copyright Text' (or the 'Header.javajetinc' itself).

Reproducible: Always

Steps to Reproduce:
1. Change the 'Copyright Text' in your Genmodel
2. Generate code
3. Open a generated class of your choise and check if the header has the new copyright text
Comment 1 Ed Merks CLA 2011-02-10 03:48:29 EST
That's working as designed.  The copyright header is generally modified after being generated, e.g., copyright dates, names of copyright holders and names of additional contributors as their contributions are committed.  If you've not modified anything yet, you can delete all the files to generate fresh ones with the initial copyright notices of your design.
Comment 2 Bernd Vogt CLA 2011-02-10 04:11:43 EST
(In reply to comment #1)
> That's working as designed.  The copyright header is generally modified after
> being generated, e.g., copyright dates, names of copyright holders...

Indeed, but in our case it would be much better (and smarter) to use the copyright text from the genmodel or just to adjust a single custom header template. Actually I tried exactly this and wondered why the generation of the header doesn't behave like the rest...

I expected the header generation to behave like the generation of the jdoc. Sth. like "<!-- begin-user-doc --><!-- end-user-doc -->" would be nice and could helping out with "names ofadditional contributors".

> If you've not
> modified anything yet, you can delete all the files to generate fresh ones

Sadly, we have a bunch of operations and customizations... I solved the problem with a creepy regex...
Comment 3 Bernd Vogt CLA 2011-02-10 04:33:34 EST
Additionally, who cares about the header when generating code for a model the first time? I think very few till nobody. So, you are automatically forced to delete the generated stuff at least for one time. Hopefully, you haven't made some customizations...

But I agree, headers won't change that often. So, I think it's not that important.