@@ -3,6 +3,45 @@ version: "3"
33# https://taskfile.dev/usage/#env-files
44dotenv : [".env.local", ".env"]
55
6+ includes :
7+ translation :
8+ taskfile : ./task/Taskfile.translation.yml
9+ vars :
10+ TRANSLATION_MODULES :
11+ # - aarhus_hero
12+
13+ - hoeringsportal_anonymous_edit
14+ # - hoeringsportal_audit_log
15+ # - hoeringsportal_base_fixtures
16+ - hoeringsportal_citizen_proposal
17+ - hoeringsportal_citizen_proposal_archiving
18+ # - hoeringsportal_config_settings
19+ # - hoeringsportal_content_access
20+ # - hoeringsportal_content_blocks
21+ # - hoeringsportal_data
22+ # - hoeringsportal_deskpro
23+ - hoeringsportal_dialogue
24+ # - hoeringsportal_forms
25+ - hoeringsportal_hearing
26+ # - hoeringsportal_misc
27+ # - hoeringsportal_openid_connect
28+ # - hoeringsportal_project
29+ - hoeringsportal_project_timeline
30+ - hoeringsportal_public_meeting
31+ - hoeringsportal_quicklinks
32+ # - hoeringsportal_test_delta_sync_fixtures
33+
34+ - itk_admin
35+ - itk_admin_links
36+ # - itk_media_entity
37+
38+ TRANSLATION_THEMES :
39+ - hoeringsportal
40+ # - hoeringsportal_admin
41+
42+ TRANSLATION_LANGUAGES :
43+ - da
44+
645vars :
746 # https://taskfile.dev/reference/templating/
847 BASE_URL : ' {{.TASK_BASE_URL | default .COMPOSE_SERVER_DOMAIN | default .COMPOSE_DOMAIN | default "https://deltag.local.itkdev.dk"}}'
@@ -314,18 +353,9 @@ tasks:
314353 translations:import :
315354 cmds :
316355 - task compose -- exec phpfpm bash -c '(cd web && ../vendor/bin/drush locale:import --type=customized --override=all da ../translations/custom-translations.da.po)'
317- - task drush -- php:eval "var_export(\Drupal::state()->get('locale.translation.formulae', []))"
318- - ' task drush -- php:eval "var_export(array_map(static fn (\$count) => (new \Drupal\Core\StringTranslation\PluralTranslatableMarkup(\$count, '' 1 item'' , '' @count items'' , options: ['' langcode'' => '' da'' ]))->render(), range(0, 5)));"'
319- - ' task drush -- php:eval "var_export(array_map(static fn (\$count) => (new \Drupal\Core\StringTranslation\PluralTranslatableMarkup(\$count, '' 1 item'' , '' @count items'' , options: ['' langcode'' => '' en'' ]))->render(), range(0, 5)));"'
320- silent : true
321-
322- translations:export :
323- cmds :
324- - task compose -- exec phpfpm bash -c '(cd web && ../vendor/bin/drush locale:export da --types=customized > ../translations/custom-translations.da.po)'
325- # Fix plurals spec in PO file
326- # https://drupalsun.com/eelke/2020/08/17/tale-mistranslated-plurals
327- # https://www.drupal.org/project/drupal/issues/3496223
328- - ' task compose -- exec phpfpm sed -i "s/Plural-Forms: nplurals=2; plural=(n > 1);/Plural-Forms: nplurals=2; plural=(n != 1);/" translations/custom-translations.da.po'
356+ - task drush -- locale:check
357+ - task drush -- locale:update
358+ - task drush -- cache:rebuild
329359 silent : true
330360
331361 # Development settings tasks (`/admin/config/development/settings`) (cf. https://www.drupal.org/docs/develop/development-tools/disabling-and-debugging-caching).
0 commit comments