akkoma-fe/src/services/version/version.service.js

7 lines
158 B
JavaScript
Raw Normal View History

2019-03-11 02:06:51 +01:00
export const extractCommit = versionString => {
2019-07-03 18:02:56 +02:00
const regex = /-g(\w+)/i
2019-03-11 02:06:51 +01:00
const matches = versionString.match(regex)
return matches ? matches[1] : ''
}