Pull stdout out of results argument

This commit is contained in:
Kevin Sawicki
2014-01-14 16:39:11 -08:00
parent a53d223b6f
commit 8acd84c7e2

View File

@@ -11,8 +11,8 @@ module.exports = (grunt) ->
else
cmd = 'git'
args = ['rev-parse', '--short', 'HEAD']
spawn {cmd, args}, (error, result='', code) ->
callback(error, result.trim?() ? result)
spawn {cmd, args}, (error, {stdout}={}, code) ->
callback(error, stdout?.trim?())
grunt.registerTask 'set-version', 'Set the version in the plist and package.json', ->
done = @async()