wpbp/generator
Composer 安装命令:
composer require wpbp/generator
包简介
Generator of Wordpress Plugin Boilerplate Powered
关键字:
README 文档
README
This generator (based on PHP) parse the WordPress Plugin Boilerplate Powered and remove the stuff that you don't need.
Requirements
Let's have a look on what you need and how to install it:
Debian/Ubuntu
sudo apt install php php-zip php-mbstring php-yaml
Fedora/Centos
sudo dnf install php php-zip php-mbstring php-yaml
Mac OS
brew install pkg-config zlib
pecl install zip mbstring yaml
(source: https://grrr.tech/posts/installing-homebrew-php-extensions-with-pecl)
Install
From here you can download the phar version or you can chose to install it with composer:
composer global require wpbp/generator:dev-master
Add this directory to your PATH in your ~/.bash_profile (or ~/.bashrc) like this:
export PATH=~/.composer/vendor/bin:$PATH
Execute
wpbp-generator --help to get a list of commands
--dark
Use a dark theme for console output.
--dev
Download from the master branch (the development version).
--help
Show the help page for this command.
--json
Generate a wpbp.json file in the current folder. Suggested to use the WordPress plugin folder.
--no-download
Do you want to execute composer and npm manually? This is your flag!
--verbose
Verbose output. Because this can be helpful for debugging!
wpbp.json
This file contains all the default variables that will be used to scaffold the boilerplate.
- plugin/author section includes Plugin names for the WordPress plugin standard but also the Comments section in every file
- public-assets section includes code for frontend that enqueue CSS and JS file
- act-deact section includes the code on activation/deactivation of the plugin itself and the uninstall.php file
- admin-assets section includes code for backend that enqueue CSS and JS file,
settingsvalues are for the Plugin setting page and admin for the rest of backend,admin-pageadd a new setting plugin page - ajax section add code for WordPress Ajax system for logged/non-logged users
- git-repo execute automatically
git initin the folder created - block adds the support for a custom block, grumphp adds the support for GrumPHP and phpstan for PHPStan
- phpcs/phpstan enable predefined settings and rulesets for this tools
- unit-test adds the
testsfolder andcodeception.dist.ymlfile with the various packages for composer about Codeception - wpcli adds the support in the plugin code for the WP-CLI tool
- language-files adds the po/mo files and the code to load custom languages files
- libraries includes all the composer packages that will be downloaded with the related example code in the boilerplate itself, removing them will not add it
- snippet in the various subsections add specific code snippet integrated for the various needs in WordPress, removing them will not add it
wpbp/generator 适用场景与选型建议
wpbp/generator 是一款 基于 PHP 开发的 Composer 扩展包,目前已累计 2.33k 次下载、GitHub Stars 达 82, 最近一次更新时间为 2016 年 08 月 31 日, 在 PHP 生态内属于活跃度较高的组件。
它主要适用于以下技术方向: 「generator」 「plugin」 「wordpress」 等业务场景。在实际项目中,围绕这些方向常见需要落地的问题包括:接口对接、性能调优、并发安全、与既有框架(Laravel / ThinkPHP / Yii / Webman 等)的兼容适配,以及生产环境的日志埋点与稳定性保障。
我们在过去多个企业项目中使用过 wpbp/generator 或与其功能相近的方案,如果你在选型或落地过程中遇到问题,例如 版本兼容、二次改造、私有化封装、与内部系统对接、生产 BUG 排查,欢迎联系我们协助评估。
基于 wpbp/generator 在你已有业务上做功能扩展、字段裁剪、UI 适配、与内部账号 / 权限 / 日志系统的深度对接。
线上偶发问题、内存泄漏、慢查询、并发异常等排查修复;针对高流量场景做缓存、队列、索引层面的调优。
承接完整的项目从需求 → 设计 → 开发 → 上线 → 长期运维;也可按月提供技术保姆服务。
与 wpbp/generator 相关的其它包
同方向 / 同关键字的高下载量 PHP Composer 包推荐,方便对比选型:
Memio's PrettyPrinter, used to generate PHP code from given Model
CakePHP 4.x AdminLTE Theme.
Plugin for YOURLS. Default tools to use in some laemmi plugins
Phalcon Model Generator
Auto-generate dummy data with realistic relationships per Model-like config classes
Php class generator
统计信息
- 总下载量: 2.33k
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 83
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: GPL-3.0-or-later
- 更新时间: 2016-08-31