lib/bones/annotation_extractor.rb
# Iterate over all the files in the project manifest and extract
# annotations from the those files. Returns the results as a hash for
# display.
#
Iterate over all the files in the project manifest and extract
annotations from the those files. Returns the results as a hash for
display.
Iterate over all the files in the project manifest and extract annotations from the those files . Returns the results as a hash for display .
def find
    results = {}
    rgxp = %r/(#{tag}):?\s*(.*?)(?:\s*(?:-?%>|\*+\/))?$/o
    extensions = project.notes.extensions.dup
    exclude = if project.notes.exclude.empty? then nil
              else Regexp.new(project.notes.exclude.join('|')) end
    project.gem.files.each do |fn|
      next if exclude && exclude =~ fn
      next unless extensions.include? File.extname(fn)
      results.update(extract_annotations_from(fn, rgxp))
    end
    results
  end
def find results = { } rgxp = %r/ ( #{ tag } ):? \s *(.*?)(?: \s *(?:-?%>| \* + \/ ))?$ /o extensions = project . notes . extensions . dup exclude = if project . notes . exclude . empty? then nil else Regexp . new ( project . notes . exclude . join ( '|' ) ) end project . gem . files . each do | fn | next if exclude && exclude =~ fn next unless extensions . include? File . extname ( fn ) results . update ( extract_annotations_from ( fn , rgxp ) ) end results end
Iterate over all the files in the project manifest and extract
annotations from the those files.
Iterate over all the files in the project manifest and extract annotations from the those files .