def contents(path = nil)
      contents = []

      object = find_object(path || '/')
      contents << path unless path.nil? || object.nil?
      if object.is_a? Grit::Tree
        (object.blobs + object.trees).each do |obj|
          contents += contents(path.nil? ? obj.basename : File.join(path, obj.basename))
        end
      end

      contents
    end
def contents(path = nil)
      contents = []

      object = find_object(path || '/')
      contents << path unless path.nil? || object.nil?
      if object.is_a? Grit::Tree
        (object.blobs + object.trees).each do |obj|
          contents += contents(path.nil? ? obj.basename : File.join(path, obj.basename))
        end
      end

      contents
    end
Gets a list of files and directories in the specified path inside the
 repository

 @param [String] path The path to search for inside the repository
 @return [Array<String>] All files and directories found in the specidied
         path