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

Missing default translation file #118

Closed
raamdev opened this Issue Jul 15, 2015 · 22 comments

Comments

Projects
None yet
4 participants
@raamdev
Contributor

raamdev commented Jul 15, 2015

The Lite and Pro versions of the plugin are currently missing a default translation file (e.g., includes/translations/comment-mail.pot). We'll need to have that added so that users can start contributing translations into other languages.

@raamdev raamdev added the bug label Jul 15, 2015

@Li-An

This comment has been minimized.

Li-An commented Jul 15, 2015

I agree with that :-)

@jaswrks

This comment has been minimized.

Member

jaswrks commented Jul 15, 2015

@kristineds Interested in learning how to generate the POT file for Comment Mail?

@kristineds

This comment has been minimized.

Contributor

kristineds commented Jul 15, 2015

Interested in learning how to generate the POT file for Comment Mail?

Definitely. Count me in! Where should I start?

@jaswrks

This comment has been minimized.

Member

jaswrks commented Jul 15, 2015

Prerequisites

  • Create a directory on your system in a place where you want to keep tools like these. I suggest: ~/projects/websharks (i.e., /Users/kristine/projects/websharks)

Tools You'll Need

Gettext Translation Utility

$ brew install gettext
$ brew link gettext --force

WebSharks POT Generator for WordPress

$ git clone https://github.com/websharks/wp-i18n-tools ~/projects/websharks/wp-i18n-tools

Repos You'll Need

$ git clone https://github.com/websharks/comment-mail ~/projects/websharks/comment-mail
$ git clone https://github.com/websharks/comment-mail-pro ~/projects/websharks/comment-mail-pro

Branches You'll Need

You'll want to create two new "feature" branches that you can submit for review when you're done. Once you generate the POT translation files, you will open two Pull Requests on GitHub and request that your feature branches be merged with the latest development copy.

Lite Version

$ cd ~/projects/websharks/comment-mail
$ git checkout 000000-dev # Start from the dev branch.
$ git pull # To be sure that you're working from the latest remote copy.
$ git checkout -b feature/118 # A feature branch for this GitHub issue number.
$ git status # Quick review. You should be on branch feature/118

Pro Version

$ cd ~/projects/websharks/comment-mail-pro
$ git checkout 000000-dev # Start from the dev branch.
$ git pull # To be sure that you're working from the latest remote copy.
$ git checkout -b feature/118 # A feature branch for this GitHub issue number.
$ git status # Quick review. You should be on branch feature/118

Generate the POT Translation Files

Lite Version

$ mkdir ~/projects/websharks/comment-mail/comment-mail/includes/translations
$ ~/projects/websharks/wp-i18n-tools/makepot.php wp-plugin ~/projects/websharks/comment-mail/comment-mail ~/projects/websharks/comment-mail/comment-mail/includes/translations/comment-mail.pot

Pro Version

$ mkdir ~/projects/websharks/comment-mail-pro/comment-mail-pro/includes/translations
$ ~/projects/websharks/wp-i18n-tools/makepot.php wp-plugin ~/projects/websharks/comment-mail-pro/comment-mail-pro ~/projects/websharks/comment-mail-pro/comment-mail-pro/includes/translations/comment-mail-pro.pot

Commit and Push Changes to GitHub

Lite Version

$ cd ~/projects/websharks/comment-mail
$ git status # Do a quick review. The POT file should be listed here.
$ git add --all && git commit -m 'Adding POT translation file. See: https://github.com/websharks/comment-mail/issues/118'
$ git push -u origin feature/118

Pro Version

$ cd ~/projects/websharks/comment-mail-pro
$ git status # Do a quick review. The POT file should be listed here.
$ git add --all && git commit -m 'Adding POT translation file. See: https://github.com/websharks/comment-mail/issues/118'
$ git push -u origin feature/118

Open Two Pull Requests on GitHub

If you make it this far on your own, you'll amaze me :-) Just let me know if you need any help. Once you get to this point I'll steer you through the Pull Requests in Slack. Or, if you run into any bumps just hit me on Slack too :-)

@jaswrks jaswrks added this to the Initial Public Release milestone Jul 15, 2015

@jaswrks

This comment has been minimized.

Member

jaswrks commented Jul 15, 2015

@kristineds To submit your Pull Requests

Lite Version

Pro Version

@jaswrks jaswrks added the in progress label Jul 15, 2015

@jaswrks jaswrks closed this in #119 Jul 15, 2015

@jaswrks jaswrks removed the in progress label Jul 15, 2015

jaswrks pushed a commit that referenced this issue Jul 15, 2015

jaswrks pushed a commit to websharks/comment-mail-pro that referenced this issue Jul 15, 2015

@kristineds

This comment has been minimized.

Contributor

kristineds commented Jul 15, 2015

A+ for @kristineds ~ Two PRs merged. We now have POT translation files.

Woohoo!! 👍

@Li-An

This comment has been minimized.

Li-An commented Jul 15, 2015

OK, it's my turn to work...

@raamdev

This comment has been minimized.

Contributor

raamdev commented Jul 15, 2015

A+ for @kristineds ~ Two PRs merged. We now have POT translation files.

Woohoo! Nice work @kristineds :-) Great documentation @jaswsinc!

OK, it's my turn to work...

I'm looking forward to the French translation! :-)

@Li-An

This comment has been minimized.

Li-An commented Jul 15, 2015

I have a question: what is exactly "overload property" ?

@jaswrks

This comment has been minimized.

Member

jaswrks commented Jul 15, 2015

I have a question: what is exactly "overload property" ?

There are some parts of Comment Mail that contain errors that may occur in edge cases. It's generally OK to just skip these whenever you do a translation. For instance, if you find the line of code that contains translatable text, and it's just throwing a PHP Exception; i.e., threw new \Exception([translatable text here]), you can just skip this if you like. Ideally, these will never be seen :-)

To answer your question though, see: http://php.net/manual/en/language.oop5.overloading.php

@raamdev raamdev modified the milestones: Initial Public Release, Next Release Jul 15, 2015

@Li-An

This comment has been minimized.

Li-An commented Jul 16, 2015

Thanks for the tip. As the work is bigger than expected, it's a good idea to skip error messages much more interesting in english for developpers.
I've found the link to php.net but the official french expression is "surcharge magique" that sounds... magical :-) ??? So the reason of my question.

@Li-An

This comment has been minimized.

Li-An commented Jul 20, 2015

Some more questions - sorry I work slowly on the translation:
The Act Can concern only US residents ? If so, maybe you could add an option to desactivate this because it's perturbarting if not needed.

Found "Powered by Notes" ??

@jaswrks

This comment has been minimized.

Member

jaswrks commented Jul 21, 2015

official french expression is "surcharge magique" that sounds... magical :-)

haha! Yeah, it sure does. I'd leave it in there. It sounds awesome! 😄

Some more questions - sorry I work slowly on the translation:

Oh, no worries. I imagine it must be hard work.

The Act Can concern only US residents ?

Are you referring to "overloading". Sorry, not sure I understand.

Found "Powered by Notes" ??

The "Powered by Notes" are actually just a note at the bottom of the site and at the bottom of emails that Comment Mail sends. e.g., "Powered by Comment Mail". Also known as "branding", "supporting comment mail".

@raamdev

This comment has been minimized.

Contributor

raamdev commented Jul 21, 2015

Are you referring to "overloading". Sorry, not sure I understand.

I think he's referring to the CAN-SPAM Act; is that applicable to U.S. Residents only? And if so, shouldn't non-US residents be able to disable it?

@Li-An

This comment has been minimized.

Li-An commented Jul 21, 2015

Yes, sorry, I was referring to CAN-SPAM Act. Raamdev made it much clearer.

About "Powered by Notes": this will be the message shown in footer ? The exact message ? I was excepting for "Powered by Comment Mail" or "Powered by %s".

@jaswrks

This comment has been minimized.

Member

jaswrks commented Jul 22, 2015

Yes, sorry, I was referring to CAN-SPAM Act. Raamdev made it much clearer.

I see. Thanks! :-) Yes, the CAN-SPAM Act is U.S. only and we will be working to make it possible for others to bypass this in the future, or perhaps reword this section later. You might give this a label of something like (in English): "Postal Address and Privacy Policy" and then translate.


The exact message ? I was excepting for "Powered by Comment Mail" or "Powered by %s".

The %s is replaced with the name of the software automatically. So your translation should include the %s, but you can change the "Powered by" text in your translation.

@Li-An

This comment has been minimized.

Li-An commented Jul 22, 2015

But I've got the sentence "Powered by Notes". So I will translate it into "Propulsé par Notes". But, what is "Notes" here ???

@jaswrks

This comment has been minimized.

Member

jaswrks commented Jul 22, 2015

Notes = a brief record of facts, topics, or thoughts, written down as an aid to memory.

i.e., Powered by Comment Mail

@raamdev

This comment has been minimized.

Contributor

raamdev commented Oct 8, 2015

Next Lite Release Changelog:

  • Enhancement: Added the default translation file. Translators can now build translations using the default translation file located in includes/translations/. Props @kristineds. See Issue #118.
@raamdev

This comment has been minimized.

Contributor

raamdev commented Oct 8, 2015

Next Pro Release Changelog:

  • Enhancement: Added the default translation file. Translators can now build translations using the default translation file located in includes/translations/. Props @kristineds. See Issue #118.

@websharks websharks locked and limited conversation to collaborators Dec 24, 2015

@raamdev

This comment has been minimized.

Contributor

raamdev commented Dec 24, 2015

Comment Mail v151224 has been released and includes changes from this GitHub Issue: See the v151224 announcement for further details.


This issue will now be locked to further updates. If you have something to add related to this GitHub Issue, please open a new GitHub Issue and reference this one (#118).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.