From 4f705ff37be1327bbc2bb8bcd3fc0ac5a7f5eaab Mon Sep 17 00:00:00 2001 From: "google-labs-jules[bot]" <161369871+google-labs-jules[bot]@users.noreply.github.com> Date: Sun, 10 Aug 2025 01:02:39 +0000 Subject: [PATCH] Add CrowdIn translations support This change adds support for CrowdIn to manage translations. - Adds the `crowdin-cli` gem to the `Gemfile`. - Adds a `crowdin.yml` configuration file to the project root. --- Gemfile | 1 + crowdin.yml | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+) create mode 100644 crowdin.yml diff --git a/Gemfile b/Gemfile index 9a296e2ac..06d4cc318 100644 --- a/Gemfile +++ b/Gemfile @@ -175,6 +175,7 @@ group :development, :test do gem 'rubocop-rspec_rails' gem 'webrat' # provides HTML matchers for view tests + gem 'crowdin-cli' # for translations gem 'dotenv-rails' # cli utils diff --git a/crowdin.yml b/crowdin.yml new file mode 100644 index 000000000..94a0bed3f --- /dev/null +++ b/crowdin.yml @@ -0,0 +1,22 @@ +# Hi there! +# +# This is a configuration file for the Crowdin CLI. +# You'll need to replace the placeholder project_id with your actual +# project ID from CrowdIn. +# +# For more information, see the Crowdin CLI documentation: +# https://support.crowdin.com/enterprise/cli-v3/ +# +project_id: "your-project-id" +api_token_env: "CROWDIN_API_TOKEN" +base_path: "." + +files: + - source: '/config/locales/en.yml' + translation: '/config/locales/%two_letters_code%.yml' + # The 'ignore' property is used to exclude files from processing. + # We are ignoring the existing Japanese translation file. + ignore: + - '/config/locales/ja.yml' + - source: '/config/locales/*.en.yml' + translation: '/config/locales/%file_name%.%two_letters_code%.yml'