Generates a unique build identifier from multiple package versions and git commits. Assumes git is installed.
npm install --save buildversion
var buildVersion = require("buildversion");
var data = buildVersion(["gitrunner", "package-path"]);
{
name: 'buildversion',
version: '1.0.0',
packages: {
gitrunner: {
name: 'gitrunner',
version: '0.0.3',
commit: '4ff9f2df1a51ac3417b99c801a7c88a885d5f8fe'
},
'package-path': {
name: 'package-path',
version: '0.0.1'
}
}
}