[
https://issues.apache.org/jira/browse/LUCENE-4335?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13718148#comment-13718148
]
Uwe Schindler commented on LUCENE-4335:
---------------------------------------
bq. But now I think we need to edit Uwe Schindler's groovy script to be a macro
that fails also if any files were modified.
If we change the top-level task that runs on ant validate, the problem with
that is that you are then no longer be able to run validate on a modified
checkout before committing. But I think you are thinking of running this check
only on the generated files?
We could create a separate svnkit macro that does a before/after check. I am
thinking about a groovy script that runs a check for modified files, saves that
information in a Set<?>, then calls a subant with the regenerate task and runs
the macro code again, this time adding to a different set. If the Sets are not
identical something has changed :-)
I can assist with that!
> Builds should regenerate all generated sources
> ----------------------------------------------
>
> Key: LUCENE-4335
> URL: https://issues.apache.org/jira/browse/LUCENE-4335
> Project: Lucene - Core
> Issue Type: Improvement
> Reporter: Michael McCandless
> Assignee: Michael McCandless
> Attachments: LUCENE-4335.patch, LUCENE-4335.patch
>
>
> We have more and more sources that are generated programmatically (query
> parsers, fuzzy levN tables from Moman, packed ints specialized decoders,
> etc.), and it's dangerous because developers may directly edit the generated
> sources and forget to edit the meta-source. It's happened to me several
> times ... most recently just after landing the BlockPostingsFormat branch.
> I think we should re-gen all of these in our builds and fail the build if
> this creates a difference. I know some generators (eg JavaCC) embed
> timestamps and so always create mods ... we can leave them out of this for
> starters (or maybe post-process the sources to remove the timestamps) ...
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]