Class: Spandx::Ruby::Parsers::GemfileLock
Constant Summary
collapse
- STRIP_BUNDLED_WITH =
/^BUNDLED WITH$(\r?\n) (?<major>\d+)\.\d+\.\d+/m.freeze
Constants inherited
from Core::Parser
Core::Parser::UNKNOWN
Instance Method Summary
collapse
for, parse
#all, #each, #inherited, #registry
Instance Method Details
#match?(pathname) ⇒ Boolean
9
10
11
12
13
|
# File 'lib/spandx/ruby/parsers/gemfile_lock.rb', line 9
def match?(pathname)
basename = pathname.basename
basename.fnmatch?('Gemfile*.lock') ||
basename.fnmatch?('gems*.lock')
end
|
#parse(lockfile) ⇒ Object
15
16
17
18
19
|
# File 'lib/spandx/ruby/parsers/gemfile_lock.rb', line 15
def parse(lockfile)
dependencies_from(lockfile).map do |specification|
map_from(lockfile, specification)
end
end
|