We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 02d42fd commit fe267e3Copy full SHA for fe267e3
lib/grunt/utils.js
@@ -17,7 +17,9 @@ module.exports = {
17
if (version) return version;
18
19
var package = JSON.parse(fs.readFileSync('package.json', 'UTF-8'));
20
- var match = package.version.match(/^([^\-]*)(-snapshot)?$/);
+ // TODO(brian): change `(-|rc)` to `-` in the regex below after bower
21
+ // fixes this issue: https://github.com/bower/bower/issues/782
22
+ var match = package.version.match(/^([^\-]*)(?:(-|rc)(.+))?$/);
23
var semver = match[1].split('.');
24
var hash = shell.exec('git rev-parse --short HEAD', {silent: true}).output.replace('\n', '');
25
0 commit comments