lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Uwe Schindler (JIRA)" <>
Subject [jira] [Commented] (LUCENE-7013) Move license header before package declaration in all *.java files
Date Thu, 04 Feb 2016 11:06:39 GMT


Uwe Schindler commented on LUCENE-7013:

Actually we should open a bug report at Eclipse. I am fine with cleaning all that up, but
the real bug is in Eclipse (MARS.1 only?).

As Shai already mentioned the following things are broken:
- If Eclipse automatically adds an import, it places it behind the package name (before license),
this splits your imports into 2 parts
- If you call organize imports it fcks up completely: All imports disappear in most cases,
but they are still there!!! (open the file with text editor after saving).

This is really a bug and the changes we do here are just a workaround.

> Move license header before package declaration in all *.java files
> ------------------------------------------------------------------
>                 Key: LUCENE-7013
>                 URL:
>             Project: Lucene - Core
>          Issue Type: Improvement
>            Reporter: Shai Erera
>            Assignee: Shai Erera
>            Priority: Minor
>         Attachments: LUCENE-7013.patch,
> In LUCENE-7012 we committed a change to the IDE templates to place the license header
before the package declaration in new Java files.
> I wrote a simple Python script which moves the header before the package declaration.
To be on the safe side, if a .java file does not already start with the license header or
with {{package org.apache}}, it doesn't modify it and asks for manual intervention.
> It runs quite fast, so I don't mind running and committing one module at a time.

This message was sent by Atlassian JIRA

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message