phrase / phrase-cli

CLI for the Phrase API
https://developers.phrase.com
MIT License
42 stars 6 forks source link

How to phrase force push / overwrite? #108

Closed WaKeMaTTa closed 2 years ago

WaKeMaTTa commented 2 years ago

I tried to find out how to force push using phrase v2 cli in the documentation:

but I don't find a way.

github-actions[bot] commented 2 years ago

Hello,

Thanks for reaching out to us.

This link has instructions on how to push and pull from Phrase.

Don’t hesitate to reach out again in case needed, and have a great day ahead!

Best, Ryan from the Phrase Technical Support Team

Comment by Ryan

forelabs commented 2 years ago

Hi @WaKeMaTTa,

what exactly do you mean by force? Our push and pull commands are not protected in any way so pulling will override and pushing as well.

You can specify a parameter for pushing to either update translations (default) or not:

push:

    sources:

    - file: ./locales/en.json

       params:

        update_translations: true 

https://help.phrase.com/help/configuration

WaKeMaTTa commented 2 years ago

Thanks. It's what I was asking for.

But I was expecting an option on the command, something like phrase push --update-translations.

joelharkes commented 1 year ago

It would be nice if update-translations had an option to only update keys with translations that have not already been registered on this key before this way you an work asynchronously both in file/code and in phrase and not mess up each-others keys so much.