/prestashop-maker

PrestaShop tool to generate boilerplate code

Primary LanguagePHPAcademic Free License v3.0AFL-3.0

PrestaShop Maker

GitHub release GitHub license Minimum PHP Version

PHP tests

PrestaShop Maker is a tool to generate boilerplate code for PrestaShop projects.
It uses Symfony MakerBundle to generate code and then move the changes to your own project.

Guide

Installation

  • Stable version

Download a release.

  • Latest version

Clone the repository.

git clone https://github.com/Kaudaj/prestashop-maker.git
cd prestashop-maker
composer install

Usage

PrestaShop Maker adds a new command: make-to.

php bin/console make-to <destination-path> <make-command>

Example
In your PrestaShop project, you're working on a module and you want to generate an entity.

php /path/to/prestashop-maker/bin/console make-to modules/yourmodule make:entity

Recommended: Create an alias
As you can see, it will be quickly tiring to type the whole prestashop-maker console path each time. It is highly recommended to define a simpler shortcut that you can use anywhere.

Instructions are available in this gist.
Replace <your-command> with php /path/to/prestashop-maker/bin/console make-to and your-alias with whatever you want.

Makers

Current makers

To get the list of all the available makers, you can run the following command:

php bin/console list make

To get the list of the makers from PrestaShop Maker only, run this one:

php bin/console list make:prestashop
# or
php bin/console list make:ps

Planned makers

  • make:prestashop:controller PrestaShop Controller
  • make:prestashop:kpi PrestaShop KPI
  • make:prestashop:grid PrestaShop Grid
  • make:prestashop:crud-form PrestaShop CRUD Form
  • make:prestashop:crud-cqrs PrestaShop CRUD CQRS
  • make:prestashop:cqrs PrestaShop CQRS
  • make:prestashop:settings-form PrestaShop Settings Form
  • make:prestashop:multi-lang-entity PrestaShop Multi-Lang Entity

To go further

Reporting issues

You can report issues with this module in this very repository. Click here to report an issue.

Contributing

As it is an open source project, everyone is welcome and even encouraged to contribute with their own improvements!

To contribute in the best way possible, you want to follow the PrestaShop contribution guidelines.

License

This module is released under the Academic Free License 3.0.

Contact

Feel free to contact me by email at info@kaudaj.com.