8000 Sync translations · Issue #131 · tolk/tolk · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Sync translations #131

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
johansmitsnl opened this issue Jan 29, 2017 · 1 comment
Open

Sync translations #131

johansmitsnl opened this issue Jan 29, 2017 · 1 comment

Comments

@johansmitsnl
Copy link

I'm looking for a solution to translate our rails apps.
We have a development (rails production env) environment where we want to have users to translate the environment.
Is there a way to retrieve / sync the keys to a developer so that the changes in the translations can be committed?

@madis
Copy link
Contributor
madis commented Mar 23, 2018

@johansmitsnl do you still have this issue? In case you do here's how I approached the problem.

Just to iterate that I understood correctly: Your users have translated some phrases in production app. So the translations are in production database. You want to take the translations from production database and dump them into YAML files on developers computer so they can commit them and thus make available to the production app (e.g. via Rails's I18n.t?

If that's the case then one way would be to connect to make ActiveRecord connect to prod database from developer's machine and call Tolk's dump task after:

  def dump(locale, db_url)
    ActiveRecord::Base.establish_connection(db_url)
    Tolk::Locale.dump_yaml(locale) # or Tolk::Locale.dump_all to dump all
  end

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants
0