Skip to content
Browse files

Remove "v" prefix from version tags when assigning version number

  • Loading branch information
clue committed Jul 26, 2017
1 parent 9311277 commit 9182aac0a89ee06e4b81e3014c189a86a0b7fa36
Showing with 5 additions and 3 deletions.
  1. +1 −1
  2. +1 −1 compile.php
  3. +3 −1 leproxy.php
@@ -219,7 +219,7 @@ $ php compile.php
dependencies already.
The compile script optionally accepts the version number (`VERSION` env) and
an output file name or will otherwise try to look up the last release tag,
such as `leproxy-v1.0.0.php`.
such as `leproxy-1.0.0.php`.
In addition to the above test suite, LeProxy uses a simple bash/curl-based
acceptance test setup which can also be used to check the resulting release
@@ -3,7 +3,7 @@
// explicitly give VERSION via ENV or ask git for current version
$version = getenv('VERSION');
if ($version === false) {
$version = exec('git describe --always --dirty', $unused, $code);
$version = ltrim(exec('git describe --always --dirty', $unused, $code), 'v');
if ($code !== 0) {
fwrite(STDERR, 'Error: Unable to get version info from git. Try passing VERSION via ENV' . PHP_EOL);
@@ -23,7 +23,9 @@

define('VERSION', exec('git describe --always --dirty 2>/dev/null || echo unknown'));
// get current version from git or default to "unknown" otherwise
// this line will be replaced with the static const in the release file.
define('VERSION', ltrim(exec('git describe --always --dirty 2>/dev/null || echo unknown'), 'v'));

require __DIR__ . '/vendor/autoload.php';

0 comments on commit 9182aac

Please sign in to comment.
You can’t perform that action at this time.