Skip to content
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

Update _s.pot #470

Closed
philiparthurmoore opened this issue Apr 28, 2014 · 5 comments
Closed

Update _s.pot #470

philiparthurmoore opened this issue Apr 28, 2014 · 5 comments

Comments

@philiparthurmoore
Copy link
Collaborator

If I recall correctly, _s.pot was originally generated with the command line i18n tools on WordPress.com. I've just opened up the latest file using Poedit and notice a few issues, namely the default language for the file isn't set and there's no team and team email address associated with the file. Here are a few shots of what that looks like:

Alt text

Alt text

Alt text

I'm thinking it might not be a bad idea to add a team (Automattic) and team email address (themes@wordpress.com?) to the .pot as well as a default language (English), or am I missing something?

Also, in the current version of the .pot there are 64 untranslated strings. When I create the file from scratch, there are 58 strings. I've cleaned the comment headers in the files and run a diff and these are the primary discrepancies, not including the Menu / Primary Menu changed related to #469:

Alt text

Is it necessary that we keep these in the .pot? I'm trying to think of how most translators will choose to translate their work using the .pot file, and assume (probably not a good thing) that most would use visual tools like Poedit, not command line tools.

Thoughts?

@philiparthurmoore
Copy link
Collaborator Author

Taking a look at how the default themes handle this:

It looks like I may have been over-thinking this. There's standardization across the default themes as well as _s already:

2014:

# Copyright (C) 2014 the WordPress team
# This file is distributed under the GNU General Public License v2 or later.
msgid ""
msgstr ""
"Project-Id-Version: Twenty Fourteen 1.1\n"
"Report-Msgid-Bugs-To: http://wordpress.org/tags/twentyfourteen\n"
"POT-Creation-Date: 2014-04-16 18:29:37+00:00\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"PO-Revision-Date: 2014-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"

2013:

# Copyright (C) 2014 the WordPress team
# This file is distributed under the GNU General Public License v2 or later.
msgid ""
msgstr ""
"Project-Id-Version: Twenty Thirteen 1.2\n"
"Report-Msgid-Bugs-To: http://wordpress.org/tags/twentythirteen\n"
"POT-Creation-Date: 2014-04-16 18:28:45+00:00\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"PO-Revision-Date: 2014-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"

2012:

# Copyright (C) 2014 the WordPress team
# This file is distributed under the GNU General Public License v2 or later.
msgid ""
msgstr ""
"Project-Id-Version: Twenty Twelve 1.4\n"
"Report-Msgid-Bugs-To: http://wordpress.org/tags/twentytwelve\n"
"POT-Creation-Date: 2014-04-16 18:27:55+00:00\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"PO-Revision-Date: 2014-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"

_s

# Copyright (C) 2014 Automattic
# This file is distributed under the GNU General Public License v2 or later.
msgid ""
msgstr ""
"Project-Id-Version: _s 1.0-wpcom\n"
"Report-Msgid-Bugs-To: http://wordpress.org/tags/_s\n"
"POT-Creation-Date: 2014-03-30 17:37:52+00:00\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"PO-Revision-Date: 2014-MO-DA HO:MI+ZONE\n"
"Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
"Language-Team: LANGUAGE <LL@li.org>\n"

I think we're good here on both fronts (.pot header as well as discrepancies). Closing this and handling #469 separately.

@obenland
Copy link
Member

Maybe the default themes' .pot was created with the same tool as _s'?
I'd see it as a chance to improve our pot maker to include that information maybe. I'm not an expert on pot though, and I'm not sure how important that is. @lancewillett?

@kovshenin
Copy link
Contributor

I'm not an expert on pot though

Maybe @ryanboren can help you out ;)

@samikeijonen
Copy link
Contributor

From my understanding .pot file should be made with makepot.php. That's the best tool I have found so far.

http://i18n.svn.wordpress.org/tools/trunk/

Poedit doesn't pick theme description and other header info from style.css. And it doesn't pick up custom page template names or translators notes like this /* translators: */. This might have changed in latest version of Poedit but all of those should be included in .pot file.

If there is need to add default language, team and team email address those can be added manually.

@grappler
Copy link
Collaborator

I think it would be good if we could support Poedit as it is a tool that makes it easier for translators.

I use grunt for my themes and plugins. This is the grunt tasks that I use. https://gist.github.com/grappler/10187003

The grunt task grunt-wp-i18n uses a modified version of http://i18n.svn.wordpress.org/tools/trunk/

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

6 participants