rudeshark.net/src/version.ts

13 lines
286 B
TypeScript
Raw Normal View History

2017-03-17 16:02:41 +01:00
import prominence = require('prominence');
import git = require('git-last-commit');
const getVersion = new Promise<string>(async resolve => {
const commit = await prominence(git).getLastCommit();
const version = commit.shortHash;
resolve(version);
});
export default getVersion;