I am using the npx @wordpress/create-block
tool to create my custom block plugin, during the initial installation a number for version that is inserted in package.json
, dts-dyslocosaurus.php
metadata and block.json
is requested.
How can I keep the version the same way in everyone dynamically? Because when I change the version in one of the files does not change in others.
I've used all the options I found, among them all the functions of wp-scripts (start/build)
.
package.json
{
"name": "dts-dyslocosaurus",
"version": "3.1.2"
...
}
src/block.json
{
"$schema": "https://schemas.wp.org/trunk/block.json",
"apiVersion": 3,
"name": "dts-dyslocosaurus/dts-dyslocosaurus",
"version": "3.1.1"
...
}
dts-dyslocosaurus.php
/**
* Plugin Name: Dyslocosaurus (Achievements)
* Requires at least: 6.1
* Requires PHP: 7.0
* Version: 3.1.1
* @package dts-dyslocosaurus
*/