add version in login page

This commit is contained in:
MaysWind
2020-10-31 19:12:29 +08:00
parent 15b93ade02
commit 453e41b052
6 changed files with 40 additions and 1 deletions
+7
View File
@@ -0,0 +1,7 @@
export default {
getVersion: () => {
let version = process.env.VERSION || 'unknown';
let commitHash = process.env.COMMIT_HASH || 'unknown';
return `${version}-${commitHash.substr(0, Math.min(10, commitHash.length))}`;
}
};