Skip to content

Commit

Permalink
feat!: atlas pull replacing transifex pull (#377)
Browse files Browse the repository at this point in the history
  • Loading branch information
OmarIthawi authored Mar 21, 2024
1 parent bfb2f3b commit 99968c5
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 25 deletions.
23 changes: 9 additions & 14 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -29,24 +29,19 @@ detect_changed_source_translations:
# Checking for changed translations...
git diff --exit-code $(i18n)

# Pushes translations to Transifex. You must run make extract_translations first.
push_translations:
# Pushing strings to Transifex...
tx push -s
# Fetching hashes from Transifex...
./node_modules/@edx/reactifex/bash_scripts/get_hashed_strings_v3.sh
# Writing out comments to file...
$(transifex_utils) $(transifex_temp) --comments --v3-scripts-path
# Pushing comments to Transifex...
./node_modules/@edx/reactifex/bash_scripts/put_comments_v3.sh

# Pulls translations using atlas.
pull_translations:
rm -rf src/i18n/messages
mkdir src/i18n/messages
cd src/i18n/messages \
&& atlas pull translations/frontend-app-enterprise-public-catalog/src/i18n/messages:frontend-app-enterprise-public-catalog

$(intl_imports) frontend-app-enterprise-public-catalog
&& atlas pull $(ATLAS_OPTIONS) \
translations/frontend-component-footer/src/i18n/messages:frontend-component-footer \
translations/frontend-component-header/src/i18n/messages:frontend-component-header \
translations/frontend-platform/src/i18n/messages:frontend-platform \
translations/paragon/src/i18n/messages:paragon \
translations/frontend-app-enterprise-public-catalog/src/i18n/messages:frontend-app-enterprise-public-catalog

$(intl_imports) frontend-component-header frontend-component-footer frontend-platform paragon frontend-app-enterprise-public-catalog

# This target is used by Travis.
validate-no-uncommitted-package-lock-changes:
Expand Down
1 change: 1 addition & 0 deletions src/i18n/index.jsx
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
export default [];
13 changes: 2 additions & 11 deletions src/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,9 @@ import { ErrorPage } from '@edx/frontend-platform/react';
import React from 'react';
import ReactDOM from 'react-dom';

import { messages as paragonMessages } from '@edx/paragon';
import { messages as headerMessages } from '@edx/frontend-component-header';
import { messages as footerMessages } from '@edx/frontend-component-footer';

import App from './components/app/App';

import appMessages from './i18n';
import messages from './i18n';

import './index.scss';

Expand Down Expand Up @@ -52,10 +48,5 @@ initialize({
},
auth: () => {},
},
messages: [
headerMessages,
footerMessages,
paragonMessages,
...appMessages,
],
messages,
});

0 comments on commit 99968c5

Please sign in to comment.