Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(161)

Issue 7976026: Prepare for moving grit to its own open-source project. This mostly (Closed)

Created:
9 years, 3 months ago by Jói
Modified:
9 years, 3 months ago
Reviewers:
tony, Evan Martin
CC:
chromium-reviews, pam+watch_chromium.org, Paweł Hajdan Jr., gfeher, markusheintz_
Visibility:
Public.

Description

Prepare for moving grit to its own open-source project. This involved: - Removing a grit->Chrome dependency that had been added in a unit test; - Moving the very project-specific resource_ids file to not sit in the same directory as the grit files (albeit in a hacky way; will fix this better later as per TODOs in code); and - Removing the hard-coding of "project base dir is two directories up from grit.py" and instead making that a parameter of resource_ids (as per TODO in code, this should later move to be a parameter of the .grd file). Also fixed a minor bug in relpath in misc.py, and fixed line length in grd_runner.py. The next steps will be to copy the tools/grit folder into http://code.google.com/p/grit-i18n, then in a single commit delete tools/grit from the Chrome repo and add it back in via DEPS. Follow-up fixes will address some of the TODOs, and later fixes will generalize a few things and add some features available in a different version of grit. BUG=97420 TEST=trybots should catch any breakage here Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=102276

Patch Set 1 #

Patch Set 2 : Use a super-simple approach for resource_ids as an initial step. #

Patch Set 3 : Maybe ready for review. #

Patch Set 4 : Add TODO. #

Total comments: 10

Patch Set 5 : Merge to lkgr. #

Patch Set 6 : Respond to review comments. #

Total comments: 1
Unified diffs Side-by-side diffs Delta from patch set Stats (+272 lines, -199 lines) Patch
M tools/grit/grit.py View 1 chunk +1 line, -1 line 0 comments Download
M tools/grit/grit/grd_reader_unittest.py View 2 chunks +7 lines, -3 lines 0 comments Download
M tools/grit/grit/grit_runner.py View 1 chunk +8 lines, -4 lines 0 comments Download
M tools/grit/grit/node/misc.py View 1 2 3 4 5 3 chunks +31 lines, -14 lines 1 comment Download
M tools/grit/grit/node/misc_unittest.py View 1 2 3 4 5 1 chunk +4 lines, -5 lines 0 comments Download
A tools/grit/grit/testdata/chrome/app/generated_resources.grd View 1 2 3 4 5 1 chunk +199 lines, -0 lines 0 comments Download
M tools/grit/grit/testdata/resource_ids View 1 1 chunk +1 line, -0 lines 0 comments Download
A + tools/grit/grit/testdata/tools/grit/resource_ids View 1 chunk +5 lines, -0 lines 0 comments Download
M tools/grit/grit_info.py View 1 2 3 chunks +11 lines, -2 lines 0 comments Download
M tools/grit/resource_ids View 1 1 chunk +0 lines, -170 lines 0 comments Download
A + tools/gritsettings/resource_ids View 1 1 chunk +5 lines, -0 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
Jói
Hi Tony, Finally got around to moving grit to its own open-source project. This will ...
9 years, 3 months ago (2011-09-21 21:39:45 UTC) #1
tony
LGTM, just some style nits. Sorry for the huge hackiness of the resource_ids code. http://codereview.chromium.org/7976026/diff/3002/tools/grit/grit/node/misc.py ...
9 years, 3 months ago (2011-09-21 21:54:46 UTC) #2
Jói
Thanks Tony. I've addressed your comments and will commit once try jobs pass. Cheers, Jói ...
9 years, 3 months ago (2011-09-22 14:29:06 UTC) #3
Evan Martin
http://codereview.chromium.org/7976026/diff/7001/tools/grit/grit/node/misc.py File tools/grit/grit/node/misc.py (right): http://codereview.chromium.org/7976026/diff/7001/tools/grit/grit/node/misc.py#newcode41 tools/grit/grit/node/misc.py:41: value = os.path.join(src_root_dir, value) This change broke the Ninja ...
9 years, 3 months ago (2011-09-22 18:31:00 UTC) #4
Jói
Sorry I broke the ninja build, I didn't realize that I should have tested it. ...
9 years, 3 months ago (2011-09-22 18:56:25 UTC) #5
Evan Martin
On Thu, Sep 22, 2011 at 11:55 AM, Jói Sigurðsson <joi@chromium.org> wrote: > Sorry I ...
9 years, 3 months ago (2011-09-22 18:57:38 UTC) #6
Jói
9 years, 3 months ago (2011-09-22 18:59:37 UTC) #7
> Maybe ninja should make these paths always be absolute because of bugs
> like this one...

Relative paths are cooler.  Maybe the other build systems should use
them, like ninja :)

Cheers,
Jói


2011/9/22 Evan Martin <evan@chromium.org>:
> On Thu, Sep 22, 2011 at 11:55 AM, Jói Sigurðsson <joi@chromium.org> wrote:
>> Sorry I broke the ninja build, I didn't realize that I should have
>> tested it.
>
> You didn't need to.  Your fix is fine.
>
>>  Ian Vollick in Waterloo notified me that there was a break
>> a while ago but I didn't realize until a little over half an hour ago
>> that it was Ninja-specific, and wanted to reproduce it before deciding
>> what to do.
>>
>> My pending change http://codereview.chromium.org/7995013 will fix the
>> ninja build.
>>
>> The motivation for the change was to remove the hard-coded,
>> Chrome-specific "base of checkout is two levels up" logic, as grit is
>> being moved to its own open-source project.
>>
>> Maybe it's time for a ninja trybot? :)
>
> In theory it should just match the other build systems, though in
> practice that doesn't seem to be happening.  :(
>
> Maybe ninja should make these paths always be absolute because of bugs
> like this one...
>

Powered by Google App Engine
This is Rietveld 408576698