Download .zip |
Info | Example | View files (5) | Download .zip | Reputation | Support forum | Blog | Links |
Last Updated | Ratings | Unique User Downloads | Download Rankings | |||||
2019-06-17 (Yesterday) | Not yet rated by the users | Total: Not yet counted | Not yet ranked |
Version | License | PHP version | Categories | |||
wordpress-plugin-bas 1.0 | The PHP License | 5 | PHP 5, Content management, Code Gener..., B... |
Description | Author | |||||||||||||
This package can generate a WordPress plugin from developer answers. |
|
The Wordpress Plugin Generator lets you generate a MVC base files for a new Wordpress Plugin using the Terminal. IMPORTANT This project doesn't need Wordpress to run. It is not a PLUGIN, it creates a base files for a new Wordpress Plugin.
Minimum Requirements
`
composer install
`
or download it from and run
`
php composer.phar install
`
`
chmod +x WPG
`
`
./WPG Plugin:Generator
`
After you input your information it creates a new folder on the inputted directory so unzip the "lib/wordpress-plugin-base.zip" file which contains all base plugin files there. So, scan every file inside the new plugin folder and make replacements by defined tags per inputted information. Finally, download and run composer to install dependence packages and delete the composer.phar.
There's some default file extensions to have tags replaced by the entered information. This message means the file extension you can see above is not in a default range of these extension so you can choose to make replacement tags on this file or not.
For sure! Open the file WordpressPluginGenerator.php and include the extension you want on private $validExtensions = ['php', 'json', 'tpl', 'css', 'js'];.
There's a default limit size. When a file is bigger than this default size you can choose to make replacement tags on this file or not.
For sure! Open the file WordpressPluginGenerator.php and change the limit to the number you want private $fileSizeLimit = 1024; //kb. Just keep in mind, this number is in KB!
This is a security check to make sure everything goes right with the replacements and do not try to replace on a huge file if it doesn't need.
Make sure you have write permission on the plugin destination folder, you have ZipArchive installed, you are running PHP 5.6 or greater, the WPG file has "execute mode permission" and you have successfully run composer install. If all of that is done and you are still having any problem, send me an email and I will try to help you!
Yes you can! All you need is take your base files, replace variable content with "{{tags}}", zip that and replace the file lib/wordpress-plugin-base.zip by your new zip. To see the {{tags}} it has open the file WordpressPluginGenerator.php and take a lok at the method makeReplacements()
This project is licensed under the MIT License - see the LICENSE.md file for details
Files |
File | Role | Description | ||
---|---|---|---|---|
docs (1 file) | ||||
composer.json | Data | Auxiliary data | ||
README.md | Doc. | Documentation | ||
WordpressPluginGenerator.php | Class | Class source | ||
WPG | Example | Example script |
Version Control | Unique User Downloads | |||||||
100% |
|
Applications that use this package |
If you know an application of this package, send a message to the author to add a link here.