Compare commits

...

1 Commits

Author SHA1 Message Date
9ae898427a [Build] Read commit hash from package.json
...when not building from a git repository. Fixes #1924
2018-02-22 15:08:09 -08:00

View File

@ -52,7 +52,9 @@ var gulp = require('gulp'),
var buildVariables = {
version: project.version,
timestamp: moment.utc(Date.now()).format(),
revision: fs.existsSync('.git') ? git.long() : 'Unknown',
revision: fs.existsSync('.git') ? git.long() :
project._resolved ? project._resolved.replace(/^.*#/g, "") :
'Unknown',
branch: fs.existsSync('.git') ? git.branch() : 'Unknown'
};
return fs.readFileSync("src/start.frag", 'utf-8')