i18n WordPress tools
- Improve makepot.php so that are no error reports.
- Allow add-textdomain.php to add text domain to multiple files
- To create a WordPress plugin out of this.
- create POT with strings and translator texts
- add text domain to strings
To get it running you need to download the files, clone or fork the repo.
Change the directory in command line to where the POT file should be created. Paste this code in the command line.
php C:\path\to\i18n\makepot.php wp-theme C:\path\to\theme-folder\
Change the directory in command line to where the POT file should be created Paste this code in the command line.
php C:\path\to\i18n\makepot.php wp-plugin C:\path\to\plugin-folder\
Change the directory in command line to where the text domain should be added to the strings in the file. Paste this code in the command line.
php C:\path\to\i18n\add-textdomain.php -i text-domain file.php
or
php C:\path\to\i18n\add-textdomain.php -i text-domain file.php > new-file.php
The pomo
folder is part of WordPress core. As it is a important part of this project I have inlcuded it here so that it can be edited as needed.
- [Issue Tracker] (http://github.com/grappler/i18n/issues)
- [WordPress Coding Standards] (http://make.wordpress.org/core/handbook/coding-standards/php/)
- [WordPress Documentaion Standards] (http://make.wordpress.org/core/handbook/inline-documentation-standards/php-documentation-standards/)
WooCommerce has been great help. I was able to use some of the fixes from there.
If you are having issues, please let us know. You can report them in the issues tracker.
The project is licensed under the GPL-2.0+ license.