brave / brave-browser

Brave browser for Android, iOS, Linux, macOS, Windows.

Home Page:https://brave.com

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Split `npm run sync/build` responsibilities on branding/localization files update

goodov opened this issue · comments

Right now we copy localization and branding files on top of Chromium during npm run build command. We do this, because some things are channel-dependent. This is not great as it:

  • adds a persistent delay to each npm run build command
  • doesn't allow deterministic workspace caching after npm run sync, because npm run build may rewrite some files in src/*.

On Teamcity we archive the workspace in parallel with npm run build, which may lead to invalid files being stored in cache.

The plan to fix this:

  • make all src/* modifications during applyPatches call, which is called as a part of npm run sync and also can be triggered manually as npm run apply_patches.
  • implement channel-specific modification via GN.

If things turns out to be hard to wire via GN, another option is to support --channel in sync command.