Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
16 changes: 15 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ Running the tools can be done by calling their respective binary:
### PHP CS Fixer

Initialize the configuration with:
```bash
```bash
$ php vendor/bin/prestashop-coding-standards cs-fixer:init [--dest /path/to/my/project]
```

Expand Down Expand Up @@ -99,3 +99,17 @@ $ vendor/bin/header-stamp --license=assets/afl.txt --exclude=vendor,node_modules
```

Available options are provided with `--help`.

### Bump Module Version

Bump your module version number using [Semantic Versioning](https://semver.org/) in preparation for new release.

Updates module `$this->version` value in the module main php class file and `<version>` tag in `config.xml` file (if present).

```bash
$ php vendor/bin/prestashop-coding-standards bump-version patch # 1.2.3 → 1.2.4
$ php vendor/bin/prestashop-coding-standards bump-version minor # 1.2.3 → 1.3.0
$ php vendor/bin/prestashop-coding-standards bump-version major # 1.2.3 → 2.0.0
```

The current version is read from the module main php file `$this->version` and bumped
2 changes: 2 additions & 0 deletions bin/prestashop-coding-standards
Original file line number Diff line number Diff line change
Expand Up @@ -15,8 +15,10 @@ if (file_exists($autoloadFile)) {
use Symfony\Component\Console\Application;
use PrestaShop\CodingStandards\Command\CsFixerInitCommand;
use PrestaShop\CodingStandards\Command\PhpStanInitCommand;
use PrestaShop\CodingStandards\Command\BumpVersionCommand;

$app = new Application();
$app->add(new CsFixerInitCommand());
$app->add(new PhpStanInitCommand());
$app->add(new BumpVersionCommand());
$app->run();
3 changes: 2 additions & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
"require": {
"php": ">=7.2.5",
"symfony/console": "~3.2 || ~4.0 || ~5.0 || ~6.0 || ~7.0",
"symfony/filesystem": "~3.2 || ~4.0 || ~5.0 || ~6.0 || ~7.0"
"symfony/filesystem": "~3.2 || ~4.0 || ~5.0 || ~6.0 || ~7.0",
"composer/semver": "^3.0"
},
"require-dev": {
"friendsofphp/php-cs-fixer": "^3.2"
Expand Down
164 changes: 80 additions & 84 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading