var CoreObject  = require('core-object');
var RSVP        = require('rsvp');
var gitRepoInfo = require('git-repo-info');
var simpleGit   = require('simple-git');

module.exports = CoreObject.extend({
  init: function(path) {
    this._super();
    this.path = path;
  },

  generate: function() {
    var _this = this;
    return new RSVP.Promise(function(resolve/*, reject */) {
      simpleGit(_this.path).log(function(err, log) {
        var info = log.latest;
        
        if(!info) {
          resolve();
        } else {
          resolve({
            sha: info.hash.replace("'",''),
            email: info.author_email.replace("'",''),
            name: info.author_name,
            timestamp: new Date(info.date).toISOString(),
            branch: gitRepoInfo().branch,
            tag: gitRepoInfo().tag
          });
        }
      });
    });
  }
});

@@ -438,19 +438,20 @@
     
-var info = 
+if(!log %7C%7C !
 log.
@@ -456,26 +456,29 @@
 g.latest
-;%0A
+) %7B%0A 
         
 %0A       
@@ -473,48 +473,68 @@
     
-%0A        if(!info) %7B%0A          resolve()
+ resolve();%0A        %7D else %7B%0A          var info = log.latest
 ;%0A  
@@ -535,32 +535,26 @@
 st;%0A        
-%7D else %7B
+  
 %0A          r

Update git.js