   isStatusNew: (status) ->
     @getRepo().isStatusNew(status)
 
-  # Public: Identifies if a path is new.
+  # Identifies if a path is new.
   #
   # path - The {String} path to check
   #

    catch e
      null

  statuses: null
  upstream: null
  statusTask: null

  ### Internal ###

  # Internal: Creates a new `Git` object.
  #
  # path - The {String} representing the path to your git working directory
  # options - A hash with the following keys:
  #           :refreshOnWindowFocus - If `true`, {#refreshIndex} and {#refreshStatus} are called on focus
  constructor: (path, options={}) ->
    @repo = GitUtils.open(path)
    unless @repo?
      throw new Error("No Git repository found searching path: #{path}")

    @statuses = {}
    @upstream = {ahead: 0, behind: 0}

    refreshOnWindowFocus = options.refreshOnWindowFocus ? true
    if refreshOnWindowFocus
      $ = require 'jquery'
      @subscribe $(window), 'focus', =>
        @refreshIndex()
        @refreshStatus()

    project?.eachBuffer this, (buffer) =>
      bufferStatusHandler = =>
        path = buffer.getPath()
        @getPathStatus(path) if path
      @subscribe buffer, 'saved', bufferStatusHandler
      @subscribe buffer, 'reloaded', bufferStatusHandler

  destroy: ->
    if @statusTask?
      @statusTask.abort()
      @statusTask.off()
      @statusTask = null

    if @repo?
      @repo.release()
      @repo = null

    @unsubscribe()

  ### Public ###

  # Public: Retrieves the git repository.
  #
  # Returns a new `Repository`.
  getRepo: ->

  getShortHead: ->
    @getRepo().getShortHead()

  # Restore the contents of a path in the working directory and index to the version at `HEAD`.
  #
  # This is essentially the same as running:
  # ```
