gettext/robo 问题修复 & 功能扩展

解决BUG、新增功能、兼容多环境部署,快速响应你的开发需求

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

gettext/robo

最新稳定版本:v4.1.0

Composer 安装命令:

composer require gettext/robo

包简介

Robo tasks to manage gettext

README 文档

README

Latest Version on Packagist Software License Quality Score Total Downloads

Robo task to extract gettext values from files using gettext/gettext library

Created by Oscar Otero http://oscarotero.com oom@oscarotero.com (MIT License)

Install

Using composer:

composer require gettext/robo

usage example

Create a RoboFile.php with the following code:

require 'vendor/autoload.php';

use Robo\Tasks;

class RoboFile extends Robo\Tasks
{
    use Gettext\Robo\Gettext;

    /**
     * Scan files to find new gettext values
     */
    public function gettext()
    {
        $this->taskGettext()
            //Scan folders with php files
            ->scan('templates/', '/\.php$/')
            ->scan('other-files/', '/\.php$/')

            //Save the domain1
            ->save('domain1', 'Locale/es/LC_MESSAGES/domain1.po')
            ->save('domain1', 'Locale/gl/LC_MESSAGES/domain1.po')

            //Save the domain2
            ->save('domain2', 'Locale/es/LC_MESSAGES/domain1.po')
            ->save('domain2', 'Locale/gl/LC_MESSAGES/domain1.po')

            ->run();
    }
}

Use robo to run the code:

robo gettext

Please see CHANGELOG for more information about recent changes.

The MIT License (MIT). Please see LICENSE for more information.

统计信息

  • 总下载量: 47.8k
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 8
  • 点击次数: 0
  • 依赖项目数: 1
  • 推荐数: 0

GitHub 信息

  • Stars: 7
  • Watchers: 1
  • Forks: 5
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-10-01