openl10n/cli 问题修复 & 功能扩展

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

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

openl10n/cli

Composer 安装命令:

composer create-project openl10n/cli

包简介

Command-line tool to interact with Openl10n

README 文档

README

Build status... Code quality... License MIT Packagist Dependency Status

Install

Download the last PHAR file from the releases panel and add it to your $PATH:

VERSION=vX.X.X
curl -LO "https://github.com/openl10n/openl10n-cli/releases/download/${VERSION}/openl10n.phar"
chmod +x openl10n.phar
mv openl10n.phar /usr/local/bin/openl10n

Or clone the source and build it manually using Composer and Box Project.

git clone https://github.com/openl10n/openl10n-cli.git; cd openl10n-cli
composer install
box build
mv openl10n.phar /usr/local/bin/openl10n

You can also include it directly in a PHP project by adding it in your Composer dependencies:

composer require openl10n/cli

Usage

Write a .openl10n.yml file on the root of your project:

# Server configuration
server:
    hostname: openl10n.dev # Location of your openl10n instance
    port: 80               # Specify port if needed (optional)
    use_ssl: true          # If openl10n is protected by ssl (optional)
    username: user         # User credentials (login)
    password: userpass     # User credentials (password)

# Project identifier
project: foobar

# Path to the translation files
files:
    # Example of patterns for a standard Symfony application
    - pattern: app/Resources/translations/*.<locale>.*
    - pattern: src/*Bundle/Resources/translations/*.<locale>.*

If you use versionning with this configuration file then it's better to specify server credentials outside of the project.

You can use an alias in the .openl10n.yml file:

# Server configuration
server: foobar

and reference the credentials for this alias into the $HOME/.openl10n/server.conf file:

[foobar]
hostname: openl10n.dev
port: 80
use_ssl: true
username: user
password: userpass

Upload translations:

openl10n push --locale=all

Download translations:

openl10n pull --locale=all

Select files to upload

You can select the files you want to push to the server by adding a file name list at the end of the command:

openl10n push --locale=all app/Resources/fr.yml config/translations/de.yml

Select files to download

Same thing here:

openl10n pull --locale=all app/Resources/fr.yml config/translations/de.yml

License

OpenLocalization is released under the MIT License. See the bundled LICENSE file for details.

openl10n/cli 适用场景与选型建议

openl10n/cli 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 493 次下载、GitHub Stars 达 13, 最近一次更新时间为 2014 年 01 月 01 日, 在 PHP 生态内属于活跃度较高的组件。

我们在过去多个企业项目中使用过 openl10n/cli 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。

围绕 openl10n/cli 我们能提供哪些服务?
定制开发 / 二次开发

基于 openl10n/cli 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。

BUG 修复 & 性能优化

线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。

项目外包 & 长期维护

承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。

yvsm@zunyunkeji.com QQ:316430983 微信:yvsm316 西安尊云信息科技 · 专注 PHP / Go / 分布式系统研发

统计信息

  • 总下载量: 493
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 13
  • 点击次数: 5
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 13
  • Watchers: 3
  • Forks: 11
  • 开发语言: PHP

其他信息

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