Like this:
HASH="$(git rev-parse --short HEAD)" sed 's/Version = .*/Version = "'"$HASH"'+"/' -i version.go git add version.go
Like this: