bjornjohansen/wplang
Composer 安装命令:
composer require bjornjohansen/wplang
包简介
Composer plugin to download translation files from wordpress.org
README 文档
README
Composer plugin to download translation files for WordPress core, plugins and themes from wordpress.org.
Installation
First run:
composer require bjornjohansen/wplang
Note: If you running Composer v1, make sure to require a version less than 0.2.0.
Then you’ll have to edit your composer.json file. You need to add the following section:
"extra": {
"wordpress-languages": [ "en_GB", "nb_NO", "sv_SE" ],
"wordpress-language-dir": "wp-content/languages"
}
You should probably want to customize these values to suit your needs.
Finally run:
composer update
Now Composer will try to pull down translations for your packages from wordpress.org every time you install or update a package.
CS and Testing
Prerequisites
In order to get a more consistent code style and introduce testing the project provides some commands to test in an isolated environment.
To use the Makefile, ensure the following dependencies are installed on your system:
- GNU Make: Required to execute the Makefile commands. Install it via your system's package manager.
- Docker (Docker Build/Docker Compose): See https://docs.docker.com/get-started/get-docker/ for installation instructions.
Usage
The Makefile includes commands to simplify common development and deployment tasks. Run any of the following commands
by typing make <command> in your terminal:
- make help Output a help section with a brief description of the commands
- make setup Setup containers and development dependencies. This should run after
composer installin a dev environment, but can be run manually if something is missing or has changed. - make composer This runs composer in the PHP 7.2 docker container. Pass additional flags like with the
c=""option, e.g.,make composer c="install --no-autoloader" - make test Run PHPUnit tests.
- make checkcs Check the code style against the defined
phpcsrules. - make fixcs Fix the issues found by
phpcswithphpcbf. - make compat Check if the code is compatible with the specified PHP version.
Credits
This package Started as a fork of Angry Creative’s Composer Auto Language Updates, but has since been rewritten. It is not compatible with the original package at all, but this package would probably not have existed with the first. There are probably some code in this package that the original author will still recognize.
bjornjohansen/wplang 适用场景与选型建议
bjornjohansen/wplang 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 54.47k 次下载、GitHub Stars 达 20, 最近一次更新时间为 2018 年 08 月 10 日, 在 PHP 生态内属于活跃度较高的组件。
我们在过去多个企业项目中使用过 bjornjohansen/wplang 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 bjornjohansen/wplang 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
统计信息
- 总下载量: 54.47k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 20
- 点击次数: 0
- 依赖项目数: 0
- 推荐数: 1
其他信息
- 授权协议: GPL-2.0
- 更新时间: 2018-08-10