Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code | Sign in
(38)

Issue 5716047: fix svnversion skew (Closed)

Can't Edit
Can't Publish+Mail
Start Review
Created:
14 years, 4 months ago by felix8a
Modified:
14 years, 4 months ago
Reviewers:
Jasvir, metaweta
CC:
google-caja-discuss_googlegroups.com
Base URL:
http://google-caja.googlecode.com/svn/trunk/
Visibility:
Public.

Description

If you start with up-to-date trunk, do 'ant runserver', then make some edits, then do 'ant runserver' again, you can end up with a build where some files think the Caja version is '999' and other files think the version is '999m', so nothing works. There are three ways that svnversion is baked into the caja build: 1. ant target build.info always rewrites buildInfo.properties, which is where the java code reads version from. This tracks svnversion fine. 2. ant rule <transform> will cajole js and embed the buildInfo version in the generated js output. This doesn't track svnversion, because there's no way to tell <transform> to compare svnversion against the existing output. 3. some ant targets do <replace> of "%VERSION%" on js files like caja.js. This gets re-run all the time, but it doesn't track svnversion either, because the substitutions happen in-place in ant-lib. Once the substitution happens once, the version string never changes again, unless the source file changes and forces it to be re-copied first. Since it's messy in general to check if some arbitrary generated file is up-to-date with respect to svnversion, instead I've added an early rule that will delete all target js files if svnversion changes.

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+27 lines, -4 lines) Patch
M build.xml View 1 chunk +27 lines, -4 lines 0 comments Download

Messages

Total messages: 3
felix8a
14 years, 4 months ago (2012-03-01 07:29:11 UTC) #1
metaweta
lgtm
14 years, 4 months ago (2012-03-01 15:29:38 UTC) #2
felix8a
14 years, 4 months ago (2012-03-01 16:13:15 UTC) #3
@r4799
Sign in to reply to this message.

Powered by Google App Engine
RSS Feeds Recent Issues | This issue
This is Rietveld f62528b