def extract_resource_info( lines, blocks, file_name )
      blocks ? info = [] : blocks = []
      blocks.each.map do |b|
        if lines[ b[:init] ].include? "=begin resource"
          n_lines = b[:end] - b[:init] - 1
          begin
            info.push YAML.load( lines[ b[:init] +1, n_lines ].join.gsub(/\ *#/, '') )
          rescue Psych::SyntaxError => e
            puts "Error parsing block in #{file_name} file [#{b[:init]} - #{b[:end]}]"
          rescue => e
            puts e
          end
        end
      end

      info.first ? info.first : {}
    end
def extract_resource_info( lines, blocks, file_name )
      blocks ? info = [] : blocks = []
      blocks.each.map do |b|
        if lines[ b[:init] ].include? "=begin resource"
          n_lines = b[:end] - b[:init] - 1
          begin
            info.push YAML.load( lines[ b[:init] +1, n_lines ].join.gsub(/\ *#/, '') )
          rescue Psych::SyntaxError => e
            puts "Error parsing block in #{file_name} file [#{b[:init]} - #{b[:end]}]"
          rescue => e
            puts e
          end
        end
      end

      info.first ? info.first : {}
    end
Check if exist a block with resource information 'rapidoc resource block'

 @param lines [Array] lines that contain comments
 @param blocks [Hash] lines of blocks, example: { init: 1, end: 4 }
 @return [Hash] resource info