Sha256: 0d058e8ac20ea8f60faf69433d2d02b6b0f451155909aa4451788ae6356b5e52

Contents?: true

Size: 240 Bytes

Versions: 3

Compression:

Stored size: 240 Bytes

Contents

require 'technologist/rules/rule'

class FileContentRule < Rule
  attr_accessor :file_name, :file_content_pattern

  def matches?(framework_name, repository)
    !!(repository.file_content(file_name) =~ /#{file_content_pattern}/)
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
technologist-0.3.0 lib/technologist/rules/file_content_rule.rb
technologist-0.2.1 lib/technologist/rules/file_content_rule.rb
technologist-0.2.0 lib/technologist/rules/file_content_rule.rb