Committing Tagging For A New Release

Contributers: Mick Mifsud

Modified: 3 years ago

Page Permission: Public - Revision: 788

This assumes you have installed the tk-tools and can run the command "tk" and are working in a development environment with the debug option enabled in the config.php.

When editing a project check that composer has installed the tk libs source by running "tk bs" you should see all the libs and plugins branch versions. If this is not the case you need to run:

$ rm -rf vendor/ plugin/ html/theme-cube composer.lock
$ composer update --prefer-source

Now you can edit the site and the libs as needed.

Before you begin editing the source, it is generally a good idea to update the site and libs to ensure you do not get any version conflicts.

$ tk up
$ composer update

This will also update the composer.lock file and ensure you are working with the most recent third party lib sources and can fix anything that is broken before release.

Once you have tested your updates and are happy that everything is ready for release you can commit your changes:

$ tk ci 'This is a commit message'

You can and should commit often, be sure to add a message after each commit. The messages will be compiled and added to the changelog.md when a project tag is created.

You may come across some errors in a lib when committing from time to time if the repo has committed changes that you have not downloaded. It will only show this error once and you may miss it but you will know if you release the project and that lib has not been updated and is still installing an old tagged version. To fix this you need to use git and pull/push the changes manually:

$ cd vendor/uom/tk-form
$ git pull
$ git commit -m 'Fixing lib conflict'
$ git push

After you have committed changes and if you would like to see the next version number that will be released you can run the command:

$ tk tags
package                   curr         next         
uom/tkuni                 3.2.x        3.2.0        
uom/tk-form               3.0.112      3.0.114      
uom/tk-domtemplate        3.0.34       3.0.36       
uom/tk-uni                3.4.110      3.4.112      
uom/tk-mvc                3.2.26       3.2.28       
uom/tk-base               3.2.138      3.2.140      
uom/tk-framework          3.0.96       3.0.98       
uom/tk-database           3.2.48       3.2.50       
uom/tk-table              3.0.118      3.0.120      
uom/tk-auth               3.0.10       3.0.12       
uom/theme-cube            1.2.20       1.2.22       
uom/tk-ui                 3.0.86       3.0.88       
uom/tk-installers         3.0.24                    
uom/tk-plugin             3.2.8        3.2.10       
uom/tk-mail               3.0.24       3.0.26       
uom-plg/plg-ldap          3.2.8        3.2.10       
uom-plg/mailog            1.0.42       1.0.44       
uom-plg/plg-lti           3.2.6        3.2.8        
uom/theme-cube            1.2.20       1.2.22

Once you have made all the changes you require and are ready to create a new tagged release version you can run the tk command:

$ tk tag

This will create tagged releases for the project and any libs and plugins that have changed since the last tagged release. If no changes have been made that lib will be skipped.