Skip to content

Commit

Permalink
Merge pull request #1161 from IFRCGo/feature/new-translations
Browse files Browse the repository at this point in the history
Add checks for translation migrations
  • Loading branch information
tnagorra authored Dec 26, 2024
2 parents 840f468 + ac7d5f9 commit 30fe47f
Show file tree
Hide file tree
Showing 2 changed files with 163 additions and 1 deletion.
34 changes: 33 additions & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,39 @@ jobs:
- name: Identify error with translation files
run: pnpm lint:translation

unimported:
translation-migrations:
continue-on-error: true
name: Identify if translation migrations need to be generated
runs-on: ubuntu-latest
defaults:
run:
working-directory: app
needs: [ui]
steps:
- uses: actions/checkout@v4
- name: Install pnpm
uses: pnpm/action-setup@v4
- name: Install Node.js
uses: actions/setup-node@v4
with:
node-version: 20
cache: 'pnpm'
- name: Install dependencies
run: pnpm install

- uses: actions/download-artifact@v4
with:
name: ui-build
path: packages/ui/dist

- name: Identify if translation migrations need to be generated
run: |
if pnpm translatte:generate; then
# The step should fail if generation is possible
exit 1
fi
unused:
name: Identify unused files
runs-on: ubuntu-latest
needs: [ui]
Expand Down
130 changes: 130 additions & 0 deletions translationMigrations/000006-1735037040790.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,130 @@
{
"parent": "000005-1734686854016.json",
"actions": [
{
"action": "update",
"key": "localUnitHealthFacilityType",
"namespace": "countryNsOverviewContextAndStructure",
"newValue": "Health facility type"
},
{
"action": "update",
"key": "localUnitLocalUnitType",
"namespace": "countryNsOverviewContextAndStructure",
"newValue": "Local unit type"
},
{
"action": "update",
"key": "exportTableButtonLabel",
"newKey": "exportButtonLabel",
"namespace": "exportButton"
},
{
"action": "update",
"key": "exportTableDownloadingButtonLabel",
"newKey": "exportDownloadingButtonLabel",
"namespace": "exportButton"
},
{
"action": "add",
"key": "dateOfOperation",
"namespace": "operationalLearning",
"value": "Date of Operation"
},
{
"action": "add",
"key": "organizationTypesLabel",
"namespace": "operationalLearning",
"value": "Organization Type"
},
{
"action": "add",
"key": "organizationTypesLabelPlaceholder",
"namespace": "operationalLearning",
"value": "All Organization Types"
},
{
"action": "add",
"key": "perLearningTypesLabel",
"namespace": "operationalLearning",
"value": "Learning Type"
},
{
"action": "add",
"key": "perLearningTypesLabelPlaceholder",
"namespace": "operationalLearning",
"value": "All Learning Type"
},
{
"action": "remove",
"key": "dateOfLearning",
"namespace": "operationalLearning"
},
{
"action": "update",
"key": "filterComponentLabel",
"namespace": "operationalLearning",
"newValue": "PER Component"
},
{
"action": "remove",
"key": "backToEventsLabel",
"namespace": "riskImminentEventMap"
},
{
"action": "remove",
"key": "eventDetailsStartedOn",
"namespace": "riskImminentEvents"
},
{
"action": "remove",
"key": "eventStartOnLabel",
"namespace": "riskImminentEvents"
},
{
"action": "remove",
"key": "meteoSwissEventDetailsStartedOnLabel",
"namespace": "riskImminentEvents"
},
{
"action": "remove",
"key": "meteoSwissEventDetailsUpdatedAtLabel",
"namespace": "riskImminentEvents"
},
{
"action": "remove",
"key": "wfpEventDetailsPublishedOn",
"namespace": "riskImminentEvents"
},
{
"action": "update",
"key": "eventListViewDetails",
"namespace": "riskImminentEvents",
"newValue": "View / Hide Details"
},
{
"action": "update",
"key": "gdacsEventViewDetails",
"namespace": "riskImminentEvents",
"newValue": "View / Hide Details"
},
{
"action": "update",
"key": "meteoSwissEventListViewDetails",
"namespace": "riskImminentEvents",
"newValue": "View / Hide Details"
},
{
"action": "update",
"key": "wfpEventListViewDetails",
"namespace": "riskImminentEvents",
"newValue": "View / Hide Details"
},
{
"action": "update",
"key": "healthDetails",
"namespace": "surgeCatalogueHealth",
"newValue": "The IFRC and its member National Societies have a network of personnel, equipment and approaches to prevent, detect and respond to health needs in emergencies, including both clinical and public health Emergency Response Units. These health response tools prevent and treat illness and improve health and dignity for communities affected by slow- and sudden-onset disasters or outbreaks. Deployable health capacities can support inter-agency health coordination, overall strategic direction for health, implementation of community- and clinic-based health interventions, and provide critical lifesaving services to communities, in support of government health systems and services."
}
]
}

0 comments on commit 30fe47f

Please sign in to comment.