Module: Gemfilelint::Parser

Defined in:
lib/gemfilelint.rb

Defined Under Namespace

Classes: Invalid, Valid

Class Method Summary collapse

Class Method Details

.for(path) ⇒ Object



101
102
103
104
105
# File 'lib/gemfilelint.rb', line 101

def self.for(path)
  Valid.new(path, Bundler::Dsl.new.tap { |dsl| dsl.eval_gemfile(path) })
rescue Bundler::Dsl::DSLError
  Invalid.new(path)
end