Thursday, November 10, 2022

[FIXED] What is the best way to versoining in install/ upgrade scripts?

Issue

Sometimes, I use any of the following mentioned names to name the install/upgrade scripts in custom modules:

install-0.1.0.0.php
upgrade-0.1.0.0-0.1.1.0.php
upgrade-0.1.1.0-0.1.2.0.php

----------------------------

install-0.1.0.php
upgrade-0.1.0.0-0.1.1.php
upgrade-0.1.1-0.1.2.php

Is there a standard way to follow for this naming conventions for install/upgrade scripts?


Solution

Versioning follows some conventions/standards, here is the code snippet from Mage.php to give an idea how module versions can be decided. This is for Magento version 1.7.0.2

array( 'major' => '1', 'minor' => '7', 'revision' => '0', 'patch' => '2', 'stability' => '', 'number' => '', );



Answered By - Diwaker Tripathi
Answer Checked By - Dawn Plyler (PHPFixing Volunteer)

No comments:

Post a Comment

Note: Only a member of this blog may post a comment.