add the length to the build block to see if it fixes a bug

This commit is contained in:
Nabeel Shahzad
2018-01-09 09:13:58 -06:00
parent 5e097e9d89
commit 458ee93974
2 changed files with 4 additions and 2 deletions
+1 -1
View File
@@ -20,7 +20,7 @@ class Version extends BaseCommand
$cfg = Yaml::parse(file_get_contents($version_file)); $cfg = Yaml::parse(file_get_contents($version_file));
exec($cfg['git']['git-local'], $version); exec($cfg['git']['git-local'], $version);
$version = substr($version[0], 0, 6); $version = substr($version[0], 0, $cfg['build']['length']);
$cfg['build']['number'] = $version; $cfg['build']['number'] = $version;
file_put_contents($version_file, Yaml::dump($cfg, 4, 2)); file_put_contents($version_file, Yaml::dump($cfg, 4, 2));
+3 -1
View File
@@ -7,7 +7,9 @@ current:
format: '{$major}.{$minor}.{$patch}' format: '{$major}.{$minor}.{$patch}'
build: build:
mode: number mode: number
number: 18cb95 length: 6
increment_by: 1
number: 5e097e
git_absorb: git-local git_absorb: git-local
git: git:
git-local: 'git rev-parse --verify HEAD' git-local: 'git rev-parse --verify HEAD'