Skip to content

Commit

Permalink
Fix open source codegen.
Browse files Browse the repository at this point in the history
GitOrigin-RevId: 06fd2205ad6ef7a9ee851f214dc46f0a78ca502f
  • Loading branch information
cpojer committed Jun 14, 2024
1 parent 1f05c50 commit 6bd9fa3
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion codegen/generate-translations.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ type EntityDescription = Readonly<{
}>;

const root = process.cwd();
const isOpenSourceRepository = isOpenSource();
const publishedCampaigns = new Map([
['proto-campaign', Number.POSITIVE_INFINITY],
['the-athena-crisis', Number.POSITIVE_INFINITY],
Expand Down Expand Up @@ -82,7 +83,13 @@ const campaigns = await Promise.all(
);

const campaignMetadata: Array<string> = [];
const campaignMaps = isOpenSource()
if (isOpenSourceRepository) {
campaignMetadata.push(
`'placeholder-campaign': () => String(fbt(\`placeholder-campaign\`, ${JSON.stringify(`Translation for campaign name 'placeholder-campaign'.`)})),`,
);
}

const campaignMaps = isOpenSourceRepository
? maps.map((map) => ({
campaignName: 'placeholder-campaign',
map: map.module,
Expand Down

0 comments on commit 6bd9fa3

Please sign in to comment.