2017 © Pedro Peláez
 

library corley-version

Manage version and bump in your ZF2 application

image

gianarb/corley-version

Manage version and bump in your ZF2 application

  • Monday, February 23, 2015
  • by GianArb
  • Repository
  • 1 Watchers
  • 3 Stars
  • 53 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 2 Forks
  • 1 Open issues
  • 7 Versions
  • 0 % Grown

The README.md

Manage version bump in your Zend Framework Application, (*1)

  • Master Travis-CI: Build Status

Console Command

php index.php version-show

Return current version, (*2)

php index.php version-bump 0.0.1

Bump version 0.0.1 * Write or edit VERSION file * Add version node in your global.php configuration file, (*3)

View Helper

You can use $this->version() to append the version number in your static resources, (*4)

<html>
    ...    
    <?php echo $this->headScript()
        ->prependFile($this->basePath("/js/script.js?v={$this->vesion()}"))
        ->prependFile($this->basePath('/js/bootstrap.min.js'))
        ->prependFile($this->basePath('/js/jquery.min.js'))
    ; ?>
    ...
</html>

Configuration

<?php
return array(
    'corley-version' => array(
        'version-file-path' => ".",
        'config-path' => "./config/autoload/global.php",
    )
);

version-file-path is path of VERSION file, (*5)

Write 'version' node into config-path, (*6)

Event Driven

version-bump <version> trigger version.bump event. This module attach only one listener, (*7)

/** @var \Zend\EventManager\EventManager $em */
$em->getSharedManager()->attach('version' ,'version.bump', function($e){
    $e->getTarget()->bump($e->getParams()['version']);
}, 100);

The Versions

23/02 2015
23/02 2015
11/11 2014

dev-feature/writer-config-service

dev-feature/writer-config-service

Manage version and bump in your ZF2 application

  Sources   Download

MIT

The Requires

 

The Development Requires

11/10 2014

dev-feature/event-driven

dev-feature/event-driven

Manage version and bump in your ZF2 application

  Sources   Download

MIT

The Requires

 

The Development Requires

07/10 2014

0.0.1

0.0.1.0

Manage version and bump in your ZF2 application

  Sources   Download

MIT

The Requires

 

The Development Requires