定制 mirko-pagliai/me-tools 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

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

mirko-pagliai/me-tools

最新稳定版本:2.26.0

Composer 安装命令:

composer require mirko-pagliai/me-tools

包简介

MeTools plugin for CakePHP

README 文档

README

Software License CI codecov Codacy Badge CodeFactor

MeTools is a CakePHP plugin to improve applications development. It provides some useful tools, such as components, helpers and javascript libraries. Refer to our API to discover them all.

Installation

You can install the plugin via composer:

$ composer require --prefer-dist mirko-pagliai/me-tools

Then you have to load the plugin. For more information on how to load the plugin, please refer to the Cookbook.

Simply, you can execute the shell command to enable the plugin:

bin/cake plugin load MeTools

This would update your application's bootstrap method.

Installation on older CakePHP and PHP versions

Recent packages and the master branch require at least CakePHP 4.2 and PHP 7.4 and the current development of the code is based on these and later versions of CakePHP and PHP. However, there are still some branches compatible with previous versions of CakePHP and PHP.

For PHP 7.2 or later

The php7.2 branch requires at least PHP 7.2.

In this case, you can install the package as well:

$ composer require --prefer-dist mirko-pagliai/me-tools:dev-php7.2

Note that the php7.2 branch will no longer be updated as of May 13, 2022, except for security patches, and it matches the 2.20.9 version.

Use the theme for Bake

MeTools includes a theme for Bake. For information on Bake's themes, refer to the CookBook.

If you want to use this theme, don't forget to use the --theme MeTools option when you Bake, or to set the theme as default:

<?php
// in src/Application::bootstrapCli() before loading the 'Bake' plugin.
Configure::write('Bake.theme', 'MeTools');

How to extract POT files

First, copy the CakePHP binaries (at least bin/cake and bin/cake.php), adapting bin/cake.php to the plugin.

For example, it might look like this:

#!/usr/bin/php -q
<?php
declare(strict_types=1);

require_once dirname(__DIR__) . '/tests/bootstrap.php';

use App\Application;
use Cake\Console\CommandRunner;

// Build the runner with an application and root executable name.
$runner = new CommandRunner(new Application(APP . '/config'), 'cake');
exit($runner->run($argv));

Then run the extract command in the console:

$ bin/cake i18n extract --paths config,src,templates --overwrite

Versioning

For transparency and insight into our release cycle and to maintain backward compatibility, MeTools will be maintained under the Semantic Versioning guidelines.

统计信息

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

GitHub 信息

  • Stars: 2
  • Watchers: 2
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: MIT
  • 更新时间: 2015-06-09